WP_Upgrader::release_lock() WordPress Method

The WP_Upgrader::release_lock() method is used to release a lock on a process that is currently running. This is useful for when a process needs to be interrupted and another process needs to take over.

WP_Upgrader::release_lock( string $lock_name ) #

Releases an upgrader lock.


Description

Top ↑

See also


Top ↑

Parameters

$lock_name

(string)(Required)The name of this unique lock.


Top ↑

Return

(bool) True if the lock was successfully released. False on failure.


Top ↑

Source

File: wp-admin/includes/class-wp-upgrader.php

	public static function release_lock( $lock_name ) {
		return delete_option( $lock_name . '.lock' );
	}


Top ↑

Changelog

Changelog
VersionDescription
4.5.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.