Overview
Comment:Fix FileSystem quota iterator
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | dev
Files: files | file ages | folders
SHA3-256: 2aa74b5e6179a410d6f46484c481ea253399a6f1a0f27d747fe6d7c46fd50c81
User & Date: bohwaz on 2021-04-07 22:17:38
Other Links: branch diff | manifest | tags
Context
2021-04-08
10:23
Release 1.1.0-rc2, merge with trunk changes check-in: 2766cf833f user: bohwaz tags: dev, 1.1.0-rc2
2021-04-07
22:17
Fix FileSystem quota iterator check-in: 2aa74b5e61 user: bohwaz tags: dev
18:58
Fix in case string is null check-in: 82ea8f2e97 user: bohwaz tags: dev
Changes

Modified src/include/lib/Garradin/Files/Storage/FileSystem.php from [7b08898a49] to [c12d0e525f].

216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
			return self::$_size;
		}

		$total = 0;

		$path = self::_getRoot();

		foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($path, \FilesystemIterator::SKIP_DOTS,), \RecursiveIteratorIterator::CATCH_GET_CHILD) as $p) {
			$total += $p->getSize();
		}

		self::$_size = (int) $total;

		return self::$_size;
	}







|







216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
			return self::$_size;
		}

		$total = 0;

		$path = self::_getRoot();

		foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($path, \FilesystemIterator::SKIP_DOTS), \RecursiveIteratorIterator::LEAVES_ONLY, \RecursiveIteratorIterator::CATCH_GET_CHILD) as $p) {
			$total += $p->getSize();
		}

		self::$_size = (int) $total;

		return self::$_size;
	}