This commit is contained in:
Daniil Gentili 2019-12-27 12:24:01 +01:00
parent 79794b765e
commit 660e7112e5
1 changed files with 3 additions and 3 deletions

View File

@ -584,7 +584,7 @@ trait Tools
*/
public static function flock(string $file, int $operation, float $polling = 0.1): Promise
{
return self::call(self::flockGenerator($file, $operation, $polling));
return self::call(Tools::flockGenerator($file, $operation, $polling));
}
/**
* Asynchronously lock a file (internal generator function).
@ -595,7 +595,7 @@ trait Tools
*
* @return \Generator
*/
private static function flockGenerator(string $file, int $operation, float $polling): \Generator
public static function flockGenerator(string $file, int $operation, float $polling): \Generator
{
if (!yield exists($file)) {
yield \touch($file);
@ -648,7 +648,7 @@ trait Tools
*
* @return \Generator
*/
private static function readLineGenerator(string $prompt = ''): \Generator
public static function readLineGenerator(string $prompt = ''): \Generator
{
$stdin = getStdin();
$stdout = getStdout();