Skip to content

Commit dee9cee

Browse files
committed
Fix locking docs markdown fences
1 parent 18d1573 commit dee9cee

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

docs/en/core-libraries/locking.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ engines for Redis, Memcached, local files, and no-op/testing usage.
1313

1414
Lock engine configurations are typically defined in **config/app.php**:
1515

16-
``` php
16+
```php
1717
'Lock' => [
1818
'default' => [
1919
'className' => 'Redis',
@@ -27,7 +27,7 @@ Lock engine configurations are typically defined in **config/app.php**:
2727

2828
You can also configure lock engines at runtime:
2929

30-
``` php
30+
```php
3131
use Cake\Lock\Lock;
3232

3333
Lock::setConfig('orders', [
@@ -42,7 +42,7 @@ Lock::setConfig('orders', [
4242
Lock configurations use the same `className` conventions as other registry-based
4343
CakePHP services:
4444

45-
``` php
45+
```php
4646
Lock::setConfig('default', ['className' => 'Redis']);
4747
Lock::setConfig('default', ['className' => 'Cake\Lock\Engine\RedisLockEngine']);
4848
```
@@ -54,7 +54,7 @@ If an engine cannot be initialized, CakePHP falls back to the noop
5454

5555
Use `Lock::acquire()` to attempt a non-blocking lock:
5656

57-
``` php
57+
```php
5858
use Cake\Lock\Lock;
5959

6060
$lock = Lock::acquire('invoice-' . $invoiceId, ttl: 60);
@@ -82,7 +82,7 @@ Explicit release is still recommended for predictable behavior.
8282
In many cases, `Lock::synchronized()` is the simplest and safest API because it
8383
guarantees prompt release:
8484

85-
``` php
85+
```php
8686
$result = Lock::synchronized(
8787
'reports-daily',
8888
function () {
@@ -101,7 +101,7 @@ returns `null`.
101101
Use `Lock::acquireBlocking()` when you want to wait for a lock to become
102102
available:
103103

104-
``` php
104+
```php
105105
$lock = Lock::acquireBlocking(
106106
'payment-' . $paymentId,
107107
ttl: 60,
@@ -126,7 +126,7 @@ The `retryInterval` value is expressed in milliseconds.
126126

127127
CakePHP provides additional helper methods for lock lifecycle management:
128128

129-
``` php
129+
```php
130130
if (Lock::isLocked('imports-products')) {
131131
return;
132132
}

0 commit comments

Comments
 (0)