Skip to content

Commit f812114

Browse files
ybenhssaienjaviereguiluz
authored andcommitted
Lock - replace getExpiringDate by getRemainingLifetime
As the method `getExpiringDate` doesn't exist, replace it by `getRemainingLifetime` which returns the remaining time to live in seconds
1 parent 7d03251 commit f812114

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

components/lock.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,8 +196,8 @@ to reset the TTL to its original value::
196196
$lock->refresh(600);
197197

198198
This component also provides two useful methods related to expiring locks:
199-
``getExpiringDate()`` (which returns ``null`` or a ``\DateTimeImmutable``
200-
object) and ``isExpired()`` (which returns a boolean).
199+
``getRemainingLifetime()`` (which returns ``null`` or a ``float``
200+
as seconds) and ``isExpired()`` (which returns a boolean).
201201

202202
The Owner of The Lock
203203
---------------------

0 commit comments

Comments
 (0)