bug fixing for CleanupAssets.php