set to no limit if limit = 0

master
Jean-Christian Paul Denis 2022-12-26 21:14:13 +01:00
parent 54618a5fea
commit 44644da749
Signed by: JcDenis
GPG Key ID: 1B5B8C5B90B6C951
1 changed files with 4 additions and 0 deletions

View File

@ -357,6 +357,10 @@ class dcTranslater extends dcTranslaterDefaultSettings
*/
public static function isBackupLimit(string $id, string $root, int $limit = 10, bool $throw = false): bool
{
if (!$limit) {
return false;
}
$count = 0;
foreach (self::scandir($root) as $file) {
if (!is_dir($root . '/' . $file)