IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
|
|
|
|
| 1458 | 1458 | /** This filter is documented in wp-admin/includes/ajax-actions.php */ |
| 1459 | 1459 | $time_window = apply_filters( 'wp_check_post_lock_window', 150 ); |
| 1460 | 1460 | |
| 1461 | | if ( $time && $time > time() - $time_window && $user != get_current_user_id() ) |
| 1462 | | return $user; |
| 1463 | | return false; |
| | 1461 | $lock_status = false; |
| | 1462 | |
| | 1463 | if ( $time && $time > time() - $time_window && $user != get_current_user_id() ) { |
| | 1464 | $lock_status = $user; |
| | 1465 | } |
| | 1466 | |
| | 1467 | /** |
| | 1468 | * Filters whether to filter lock status. |
| | 1469 | * |
| | 1470 | * @since 4.7.0 |
| | 1471 | * |
| | 1472 | * @param bool|int $lock_status User ID of user with lock or false. |
| | 1473 | * @param int $post_id ID of the post to check for editing. |
| | 1474 | * @param int $time Time of locked post. |
| | 1475 | * @param int $time_window The interval in seconds the post lock duration. |
| | 1476 | * @param int $user User ID of user with lock. |
| | 1477 | */ |
| | 1478 | return apply_filters( 'wp_post_lock_status', $lock_status, $post_id, $time, $time_window, $user ); |
| 1464 | 1479 | } |
| 1465 | 1480 | |
| 1466 | 1481 | /** |