Making WordPress.org

Changeset 5057


Ignore:
Timestamp:
03/03/2017 05:55:02 PM (8 years ago)
Author:
coffee2code
Message:

Support Forums, Version Dropdown: Enqueue wporg-bbp-version-dropdown.js in plugin/theme/review forums as well.

Props SergeyBiryukov.
Fixes #2550.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-bbp-version-dropdown/inc/class-plugin.php

    r3748 r5057  
    110110
    111111    public function enqueue_scripts() {
    112         if ( bbp_is_single_forum() || bbp_is_single_topic() || bbp_is_topic_edit() ) {
     112        if (
     113            bbp_is_single_forum() || bbp_is_single_topic() || bbp_is_topic_edit()
     114        ||
     115            bbp_is_single_view() && in_array( bbp_get_view_id(), array( 'theme', 'plugin', 'reviews' ) )
     116        ) {
    113117            wp_enqueue_script( 'wporg-bbp-version-dropdown', plugins_url( 'wporg-bbp-version-dropdown.js', __DIR__ ), array( 'jquery' ), '20160729', true );
    114118        }
Note: See TracChangeset for help on using the changeset viewer.