8000 Fix documentation regarding createLock() method · fmata/symfony-docs@0760638 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0760638

Browse files
julienfalquejaviereguiluz
authored andcommitted
Fix documentation regarding createLock() method
1 parent d45c101 commit 0760638

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

components/lock.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,10 @@ create the lock for some resource::
3939
$store = new SemaphoreStore();
4040
$factory = new Factory($store);
4141

42-
Then, a call to the :method:`Symfony\\Component\\Lock\\LockInterface::acquire`
43-
method will try to acquire the lock. Its first argument is an arbitrary string
44-
that represents the locked resource::
42+
The lock can be created by calling the :method:`Symfony\\Component\\Lock\\Factory::createLock`
43+
method. Its first argument is an arbitrary string that represents the locked
44+
resource. Then, a call to the :method:`Symfony\\Component\\Lock\\LockInterface::acquire`
45+
method will try to acquire the lock::
4546

4647
// ...
4748
$lock = $factory->createLock('pdf-invoice-generation');

0 commit comments

Comments
 (0)
0