Docs: Correct a comment and `@return` entry in `WP_Upgrader::create_lock()`.

Props markshep.
Fixes #38089.
Built from https://develop.svn.wordpress.org/trunk@38622


git-svn-id: http://core.svn.wordpress.org/trunk@38565 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2016-09-18 20:16:29 +00:00
parent 65bc3d39e6
commit 05a947c05a
2 changed files with 3 additions and 3 deletions

View File

@ -833,7 +833,7 @@ class WP_Upgrader {
* @param string $lock_name The name of this unique lock. * @param string $lock_name The name of this unique lock.
* @param int $release_timeout Optional. The duration in seconds to respect an existing lock. * @param int $release_timeout Optional. The duration in seconds to respect an existing lock.
* Default: 1 hour. * Default: 1 hour.
* @return bool False if a lock couldn't be created or if the lock is no longer valid. True otherwise. * @return bool False if a lock couldn't be created or if the lock is still valid. True otherwise.
*/ */
public static function create_lock( $lock_name, $release_timeout = null ) { public static function create_lock( $lock_name, $release_timeout = null ) {
global $wpdb; global $wpdb;
@ -853,7 +853,7 @@ class WP_Upgrader {
return false; return false;
} }
// Check to see if the lock is still valid. If not, bail. // Check to see if the lock is still valid. If it is, bail.
if ( $lock_result > ( time() - $release_timeout ) ) { if ( $lock_result > ( time() - $release_timeout ) ) {
return false; return false;
} }

View File

@ -4,7 +4,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '4.7-alpha-38621'; $wp_version = '4.7-alpha-38622';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.