Plugin Directory

Changeset 3022645


Ignore:
Timestamp:
01/16/2024 09:11:57 PM (2 years ago)
Author:
macbookandrew
Message:

Update to version 1.10.0 from GitHub

Location:
wp-youtube-live
Files:
6 edited
1 copied

Legend:

Unmodified
Added
Removed
  • wp-youtube-live/tags/1.10.0/inc/admin.php

    r2980913 r3022645  
    304304        $options['debugging'] = false;
    305305    }
    306     ?>
    307     Show debugging information in an HTML comment for logged-in users? <label><input type="radio" name="youtube_live_settings[debugging]" value="true" <?php checked( $options['debugging'], 'true' ); ?>> Yes</label> <label><input type="radio" name="youtube_live_settings[debugging]" value="false" <?php checked( $options['debugging'], 'false' ); ?>> No</label>
     306
     307    /**
     308     * Filters the capability required to see debug output.
     309     *
     310     * @since 1.10.0
     311     *
     312     * @var string $capability The capability required.
     313     *
     314     * @return string
     315     */
     316    $capability = apply_filters( 'wp_youtube_live_debug_user_capability', 'manage_options' );
     317
     318    ?>
     319    Show debugging information in an HTML comment for logged-in users with the <code><?php echo esc_attr( $capability ); ?></code> capability? <label><input type="radio" name="youtube_live_settings[debugging]" value="true" <?php checked( $options['debugging'], 'true' ); ?>> Yes</label> <label><input type="radio" name="youtube_live_settings[debugging]" value="false" <?php checked( $options['debugging'], 'false' ); ?>> No</label>
    308320    <?php
    309321}
  • wp-youtube-live/tags/1.10.0/readme.txt

    r2980913 r3022645  
    55Requires at least: 3.6
    66Tested up to:      6.3.2
    7 Stable tag:        1.9.0
     7Stable tag:        1.10.0
    88License:           GPLv2 or later
    99License URI:       http://www.gnu.org/licenses/gpl-2.0.html
     
    2727You can also enable auto-refresh to automatically check for a live video every 30 seconds (warning: will increase server load, so use with caution).
    2828
    29 By default, the server will check YouTube’s API and then cache that response for 30 seconds before checking the API again. If auto-refresh is enabled, clients will check against your server every 30 seconds and likely will hit that cache as well, so it can potentially take up to 60 seconds before a client will get a live video.
     29By default, the server will check YouTube’s API and then cache that response for 15 minutes before checking the API again (you may change this value in the admin settings). If auto-refresh is enabled, clients will check against your server every 30 seconds and likely will hit that cache as well, so it can potentially take up to 16 minutes before a client will get a live video.
    3030
    3131The length of both caches can be changed using the `wp_youtube_live_transient_timeout` filter (see below for more information).
     
    179179== Changelog ==
    180180
     181= 1.10.0 =
     182- Fix `show_related` parameter
     183- Fix debug output
     184- Add capability checking to see debug output
     185
    181186= 1.9.0 =
    182187- Add YouTube Terms of Service and Google Privacy Policy
  • wp-youtube-live/tags/1.10.0/wp-youtube-live.php

    r2980913 r3022645  
    44 * Plugin URI: https://github.com/macbookandrew/wp-youtube-live
    55 * Description: Displays the current YouTube live video from a specified channel
    6  * Version: 1.9.0
     6 * Version: 1.10.0
    77 * Author: Andrew Minion
    88 * Author URI: https://andrewrminion.com/
     
    1313}
    1414
    15 define( 'WP_YOUTUBE_LIVE_VERSION', '1.9.0' );
     15define( 'WP_YOUTUBE_LIVE_VERSION', '1.10.0' );
    1616
    1717/**
     
    188188    }
    189189
     190    /**
     191     * Filters the capability required to see debug output.
     192     *
     193     * @since 1.10.0
     194     *
     195     * @var string $capability The capability required.
     196     *
     197     * @return string
     198     */
     199    $capability = apply_filters( 'wp_youtube_live_debug_user_capability', 'manage_options' );
     200
    190201    // debugging.
    191     if ( get_option( 'youtube_live_settings', 'debugging' ) && is_user_logged_in() ) {
     202    if ( 'true' === $youtube_options['debugging'] && is_user_logged_in() && current_user_can( $capability ) ) {
    192203        if ( $youtube_live->getErrorMessage() ) {
    193204            $error_message = '<p><strong>WP YouTube Live error:</strong></p>
     
    320331
    321332    // added in v1.7.0.
    322     if ( ! array_key_exists( 'show_relatetd', $request_options ) ) {
    323         $request_options['show_relatetd'] = false;
     333    if ( ! array_key_exists( 'show_related', $request_options ) ) {
     334        $request_options['show_related'] = false;
    324335    }
    325336
  • wp-youtube-live/trunk/inc/admin.php

    r2980913 r3022645  
    304304        $options['debugging'] = false;
    305305    }
    306     ?>
    307     Show debugging information in an HTML comment for logged-in users? <label><input type="radio" name="youtube_live_settings[debugging]" value="true" <?php checked( $options['debugging'], 'true' ); ?>> Yes</label> <label><input type="radio" name="youtube_live_settings[debugging]" value="false" <?php checked( $options['debugging'], 'false' ); ?>> No</label>
     306
     307    /**
     308     * Filters the capability required to see debug output.
     309     *
     310     * @since 1.10.0
     311     *
     312     * @var string $capability The capability required.
     313     *
     314     * @return string
     315     */
     316    $capability = apply_filters( 'wp_youtube_live_debug_user_capability', 'manage_options' );
     317
     318    ?>
     319    Show debugging information in an HTML comment for logged-in users with the <code><?php echo esc_attr( $capability ); ?></code> capability? <label><input type="radio" name="youtube_live_settings[debugging]" value="true" <?php checked( $options['debugging'], 'true' ); ?>> Yes</label> <label><input type="radio" name="youtube_live_settings[debugging]" value="false" <?php checked( $options['debugging'], 'false' ); ?>> No</label>
    308320    <?php
    309321}
  • wp-youtube-live/trunk/readme.txt

    r2980913 r3022645  
    55Requires at least: 3.6
    66Tested up to:      6.3.2
    7 Stable tag:        1.9.0
     7Stable tag:        1.10.0
    88License:           GPLv2 or later
    99License URI:       http://www.gnu.org/licenses/gpl-2.0.html
     
    2727You can also enable auto-refresh to automatically check for a live video every 30 seconds (warning: will increase server load, so use with caution).
    2828
    29 By default, the server will check YouTube’s API and then cache that response for 30 seconds before checking the API again. If auto-refresh is enabled, clients will check against your server every 30 seconds and likely will hit that cache as well, so it can potentially take up to 60 seconds before a client will get a live video.
     29By default, the server will check YouTube’s API and then cache that response for 15 minutes before checking the API again (you may change this value in the admin settings). If auto-refresh is enabled, clients will check against your server every 30 seconds and likely will hit that cache as well, so it can potentially take up to 16 minutes before a client will get a live video.
    3030
    3131The length of both caches can be changed using the `wp_youtube_live_transient_timeout` filter (see below for more information).
     
    179179== Changelog ==
    180180
     181= 1.10.0 =
     182- Fix `show_related` parameter
     183- Fix debug output
     184- Add capability checking to see debug output
     185
    181186= 1.9.0 =
    182187- Add YouTube Terms of Service and Google Privacy Policy
  • wp-youtube-live/trunk/wp-youtube-live.php

    r2980913 r3022645  
    44 * Plugin URI: https://github.com/macbookandrew/wp-youtube-live
    55 * Description: Displays the current YouTube live video from a specified channel
    6  * Version: 1.9.0
     6 * Version: 1.10.0
    77 * Author: Andrew Minion
    88 * Author URI: https://andrewrminion.com/
     
    1313}
    1414
    15 define( 'WP_YOUTUBE_LIVE_VERSION', '1.9.0' );
     15define( 'WP_YOUTUBE_LIVE_VERSION', '1.10.0' );
    1616
    1717/**
     
    188188    }
    189189
     190    /**
     191     * Filters the capability required to see debug output.
     192     *
     193     * @since 1.10.0
     194     *
     195     * @var string $capability The capability required.
     196     *
     197     * @return string
     198     */
     199    $capability = apply_filters( 'wp_youtube_live_debug_user_capability', 'manage_options' );
     200
    190201    // debugging.
    191     if ( get_option( 'youtube_live_settings', 'debugging' ) && is_user_logged_in() ) {
     202    if ( 'true' === $youtube_options['debugging'] && is_user_logged_in() && current_user_can( $capability ) ) {
    192203        if ( $youtube_live->getErrorMessage() ) {
    193204            $error_message = '<p><strong>WP YouTube Live error:</strong></p>
     
    320331
    321332    // added in v1.7.0.
    322     if ( ! array_key_exists( 'show_relatetd', $request_options ) ) {
    323         $request_options['show_relatetd'] = false;
     333    if ( ! array_key_exists( 'show_related', $request_options ) ) {
     334        $request_options['show_related'] = false;
    324335    }
    325336
Note: See TracChangeset for help on using the changeset viewer.