From: Björn Schießle Date: Mon, 15 Apr 2013 08:34:38 +0000 (+0200) Subject: write a info message to the log if a file gets removed from the trash bin automatically X-Git-Tag: v5.0.5RC1~2^2~1 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=1ddfefed3fbcb7c6797a342b9a3da716bccc44f7;p=nextcloud-server.git write a info message to the log if a file gets removed from the trash bin automatically --- diff --git a/apps/files_trashbin/lib/trash.php b/apps/files_trashbin/lib/trash.php index 9efb041bb9d..13823ecbba3 100644 --- a/apps/files_trashbin/lib/trash.php +++ b/apps/files_trashbin/lib/trash.php @@ -375,6 +375,7 @@ class Trashbin { $filename = $r['id']; if ( $r['timestamp'] < $limit ) { $size += self::delete($filename, $timestamp); + \OC_Log::write('files_trashbin', 'remove "'.$filename.'" fom trash bin because it is older than '.$retention_obligation, \OC_log::INFO); } } $availableSpace = $availableSpace + $size; @@ -387,6 +388,7 @@ class Trashbin { $i = 0; while ( $i < $length && $availableSpace < 0 ) { $tmp = self::delete($result[$i]['id'], $result[$i]['timestamp']); + \OC_Log::write('files_trashbin', 'remove "'.$result[$i]['id'].'" ('.$tmp.'B) to meet the limit of trash bin size (50% of available quota)', \OC_log::INFO); $availableSpace += $tmp; $size += $tmp; $i++;