1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-05 02:39:46 +02:00

Update comments

This commit is contained in:
Daniel Neto 2024-08-21 09:11:05 -03:00
parent 91ac7ba018
commit d7965a01b8
302 changed files with 56587 additions and 763 deletions

View file

@ -0,0 +1,29 @@
<?php
namespace Safe;
use Safe\Exceptions\MiscException;
/**
*
* @param int $seconds Halt time in seconds.
* @return int Returns zero on success.
*
* If the call was interrupted by a signal, sleep returns
* a non-zero value. On Windows, this value will always be
* 192 (the value of the
* WAIT_IO_COMPLETION constant within the Windows API).
* On other platforms, the return value will be the number of seconds left to
* sleep.
* @throws MiscException
* @deprecated The Safe version of this function is no longer needed in PHP 8.0+
*/
function sleep(int $seconds): int
{
error_clear_last();
$safeResult = \sleep($seconds);
if ($safeResult === false) {
throw MiscException::createFromPhpError();
}
return $safeResult;
}