API / Minn\Runtime / PostLocks

PostLocks final class

Minn\Runtime\PostLocks · public/minn/src/Minn/Runtime/PostLocks.php · 24 lines

A post's edit lock (_edit_lock, "time:user"): who holds it while it is fresh, for the editor and the autosave that must not write under it.

Used by 1

Public

staticholder(int $postId, int $askingId): int#

The user who holds a post's lock other than the one asking (wp_check_post_lock): the lock's user, or the post's last editor when it names none, while it is newer than the window (wp_check_post_lock_window, 150 seconds); 0 otherwise.