diff options
Diffstat (limited to 'apps/files_trashbin')
-rw-r--r-- | apps/files_trashbin/ajax/delete.php | 3 | ||||
-rw-r--r-- | apps/files_trashbin/ajax/list.php | 1 | ||||
-rw-r--r-- | apps/files_trashbin/ajax/preview.php | 7 | ||||
-rw-r--r-- | apps/files_trashbin/ajax/undelete.php | 3 | ||||
-rw-r--r-- | apps/files_trashbin/appinfo/info.xml | 1 | ||||
-rw-r--r-- | apps/files_trashbin/appinfo/routes.php | 1 | ||||
-rw-r--r-- | apps/files_trashbin/appinfo/update.php | 1 | ||||
-rw-r--r-- | apps/files_trashbin/appinfo/version | 2 | ||||
-rw-r--r-- | apps/files_trashbin/command/expire.php | 3 | ||||
-rw-r--r-- | apps/files_trashbin/l10n/be.js | 2 | ||||
-rw-r--r-- | apps/files_trashbin/l10n/be.json | 2 | ||||
-rw-r--r-- | apps/files_trashbin/l10n/et_EE.js | 1 | ||||
-rw-r--r-- | apps/files_trashbin/l10n/et_EE.json | 1 | ||||
-rw-r--r-- | apps/files_trashbin/l10n/zh_CN.js | 3 | ||||
-rw-r--r-- | apps/files_trashbin/l10n/zh_CN.json | 3 | ||||
-rw-r--r-- | apps/files_trashbin/lib/helper.php | 1 | ||||
-rw-r--r-- | apps/files_trashbin/lib/trashbin.php | 14 | ||||
-rw-r--r-- | apps/files_trashbin/list.php | 1 | ||||
-rw-r--r-- | apps/files_trashbin/tests/trashbin.php | 1 |
19 files changed, 28 insertions, 23 deletions
diff --git a/apps/files_trashbin/ajax/delete.php b/apps/files_trashbin/ajax/delete.php index 944e353b1eb..63002671bfa 100644 --- a/apps/files_trashbin/ajax/delete.php +++ b/apps/files_trashbin/ajax/delete.php @@ -3,7 +3,6 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * @@ -65,7 +64,7 @@ foreach ($list as $file) { OCA\Files_Trashbin\Trashbin::delete($filename, \OCP\User::getUser(), $timestamp); if (OCA\Files_Trashbin\Trashbin::file_exists($filename, $timestamp)) { $error[] = $filename; - OC_Log::write('trashbin','can\'t delete ' . $filename . ' permanently.', OC_Log::ERROR); + \OCP\Util::writeLog('trashbin','can\'t delete ' . $filename . ' permanently.', \OCP\Util::ERROR); } // only list deleted files if not deleting everything else if (!$deleteAll) { diff --git a/apps/files_trashbin/ajax/list.php b/apps/files_trashbin/ajax/list.php index a777bdcf124..46168f7865e 100644 --- a/apps/files_trashbin/ajax/list.php +++ b/apps/files_trashbin/ajax/list.php @@ -2,7 +2,6 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_trashbin/ajax/preview.php b/apps/files_trashbin/ajax/preview.php index af86dafa496..c8bae2c5ce9 100644 --- a/apps/files_trashbin/ajax/preview.php +++ b/apps/files_trashbin/ajax/preview.php @@ -3,7 +3,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Georg Ehrke <georg@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. @@ -36,13 +35,13 @@ $scalingUp = array_key_exists('scalingup', $_GET) ? (bool) $_GET['scalingup'] : if($file === '') { \OC_Response::setStatus(400); //400 Bad Request - \OC_Log::write('core-preview', 'No file parameter was passed', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'No file parameter was passed', \OCP\Util::DEBUG); exit; } if($maxX === 0 || $maxY === 0) { \OC_Response::setStatus(400); //400 Bad Request - \OC_Log::write('core-preview', 'x and/or y set to 0', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'x and/or y set to 0', \OCP\Util::DEBUG); exit; } @@ -72,5 +71,5 @@ try{ $preview->showPreview(); }catch(\Exception $e) { \OC_Response::setStatus(500); - \OC_Log::write('core', $e->getmessage(), \OC_Log::DEBUG); + \OCP\Util::writeLog('core', $e->getmessage(), \OCP\Util::DEBUG); } diff --git a/apps/files_trashbin/ajax/undelete.php b/apps/files_trashbin/ajax/undelete.php index e7d8562f57d..8eda7a8d640 100644 --- a/apps/files_trashbin/ajax/undelete.php +++ b/apps/files_trashbin/ajax/undelete.php @@ -3,7 +3,6 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> @@ -71,7 +70,7 @@ foreach ($list as $file) { if ( !OCA\Files_Trashbin\Trashbin::restore($path, $filename, $timestamp) ) { $error[] = $filename; - OC_Log::write('trashbin', 'can\'t restore ' . $filename, OC_Log::ERROR); + \OCP\Util::writeLog('trashbin', 'can\'t restore ' . $filename, \OCP\Util::ERROR); } else { $success[$i]['filename'] = $file; $success[$i]['timestamp'] = $timestamp; diff --git a/apps/files_trashbin/appinfo/info.xml b/apps/files_trashbin/appinfo/info.xml index 8735b61e2db..f8bc5e7d3d2 100644 --- a/apps/files_trashbin/appinfo/info.xml +++ b/apps/files_trashbin/appinfo/info.xml @@ -18,5 +18,4 @@ To prevent a user from running out of disk space, the ownCloud Deleted files app <documentation> <user>user-trashbin</user> </documentation> - <ocsid>166052</ocsid> </info> diff --git a/apps/files_trashbin/appinfo/routes.php b/apps/files_trashbin/appinfo/routes.php index 526ad1d4e35..99a03d6b969 100644 --- a/apps/files_trashbin/appinfo/routes.php +++ b/apps/files_trashbin/appinfo/routes.php @@ -1,6 +1,7 @@ <?php /** * @author Georg Ehrke <georg@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files_trashbin/appinfo/update.php b/apps/files_trashbin/appinfo/update.php index 94bd353eccc..e1a0cf95576 100644 --- a/apps/files_trashbin/appinfo/update.php +++ b/apps/files_trashbin/appinfo/update.php @@ -2,7 +2,6 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_trashbin/appinfo/version b/apps/files_trashbin/appinfo/version index b6160487433..844f6a91acb 100644 --- a/apps/files_trashbin/appinfo/version +++ b/apps/files_trashbin/appinfo/version @@ -1 +1 @@ -0.6.2 +0.6.3 diff --git a/apps/files_trashbin/command/expire.php b/apps/files_trashbin/command/expire.php index e7dd5c573c2..89b949bbcdf 100644 --- a/apps/files_trashbin/command/expire.php +++ b/apps/files_trashbin/command/expire.php @@ -1,7 +1,10 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_trashbin/l10n/be.js b/apps/files_trashbin/l10n/be.js index 3ed1bc6464a..c72c72bbe91 100644 --- a/apps/files_trashbin/l10n/be.js +++ b/apps/files_trashbin/l10n/be.js @@ -3,4 +3,4 @@ OC.L10N.register( { "Error" : "Памылка" }, -"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"); +"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);"); diff --git a/apps/files_trashbin/l10n/be.json b/apps/files_trashbin/l10n/be.json index 501bc5f7dfb..a2514254e13 100644 --- a/apps/files_trashbin/l10n/be.json +++ b/apps/files_trashbin/l10n/be.json @@ -1,4 +1,4 @@ { "translations": { "Error" : "Памылка" -},"pluralForm" :"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);" +},"pluralForm" :"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);" }
\ No newline at end of file diff --git a/apps/files_trashbin/l10n/et_EE.js b/apps/files_trashbin/l10n/et_EE.js index 4e74390edb1..9298fdd5b18 100644 --- a/apps/files_trashbin/l10n/et_EE.js +++ b/apps/files_trashbin/l10n/et_EE.js @@ -9,6 +9,7 @@ OC.L10N.register( "Error" : "Viga", "restored" : "taastatud", "No deleted files" : "Kustutatud faile pole", + "You will be able to recover deleted files from here" : "Sa saad siit kustutatud faile taastada", "No entries found in this folder" : "Selles kaustas ei leitud kirjeid", "Select all" : "Vali kõik", "Name" : "Nimi", diff --git a/apps/files_trashbin/l10n/et_EE.json b/apps/files_trashbin/l10n/et_EE.json index fa3aab09ba1..734c8f6f2ec 100644 --- a/apps/files_trashbin/l10n/et_EE.json +++ b/apps/files_trashbin/l10n/et_EE.json @@ -7,6 +7,7 @@ "Error" : "Viga", "restored" : "taastatud", "No deleted files" : "Kustutatud faile pole", + "You will be able to recover deleted files from here" : "Sa saad siit kustutatud faile taastada", "No entries found in this folder" : "Selles kaustas ei leitud kirjeid", "Select all" : "Vali kõik", "Name" : "Nimi", diff --git a/apps/files_trashbin/l10n/zh_CN.js b/apps/files_trashbin/l10n/zh_CN.js index 8c9512b1d66..0ef17e35d62 100644 --- a/apps/files_trashbin/l10n/zh_CN.js +++ b/apps/files_trashbin/l10n/zh_CN.js @@ -8,6 +8,9 @@ OC.L10N.register( "Delete permanently" : "永久删除", "Error" : "错误", "restored" : "已恢复", + "No deleted files" : "无已删除文件", + "You will be able to recover deleted files from here" : "你可以在此处恢复已删除的文件", + "No entries found in this folder" : "此文件夹中无项目", "Select all" : "全部选择", "Name" : "名称", "Deleted" : "已删除", diff --git a/apps/files_trashbin/l10n/zh_CN.json b/apps/files_trashbin/l10n/zh_CN.json index 895d235aadb..0349f643555 100644 --- a/apps/files_trashbin/l10n/zh_CN.json +++ b/apps/files_trashbin/l10n/zh_CN.json @@ -6,6 +6,9 @@ "Delete permanently" : "永久删除", "Error" : "错误", "restored" : "已恢复", + "No deleted files" : "无已删除文件", + "You will be able to recover deleted files from here" : "你可以在此处恢复已删除的文件", + "No entries found in this folder" : "此文件夹中无项目", "Select all" : "全部选择", "Name" : "名称", "Deleted" : "已删除", diff --git a/apps/files_trashbin/lib/helper.php b/apps/files_trashbin/lib/helper.php index 320ad2eeb8e..42412d5d4c9 100644 --- a/apps/files_trashbin/lib/helper.php +++ b/apps/files_trashbin/lib/helper.php @@ -3,7 +3,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files_trashbin/lib/trashbin.php b/apps/files_trashbin/lib/trashbin.php index b30ea7c69f8..2d4ea7adc13 100644 --- a/apps/files_trashbin/lib/trashbin.php +++ b/apps/files_trashbin/lib/trashbin.php @@ -5,13 +5,13 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Florin Peter <github@florin-peter.de> * @author Georg Ehrke <georg@owncloud.com> - * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Qingping Hou <dave2008713@gmail.com> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> + * @author Roeland Jago Douma <roeland@famdouma.nl> * @author Sjors van der Pluijm <sjors@desjors.nl> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Victor Dubiniuk <dubiniuk@owncloud.com> @@ -160,7 +160,7 @@ class Trashbin { $query = \OC_DB::prepare("INSERT INTO `*PREFIX*files_trash` (`id`,`timestamp`,`location`,`user`) VALUES (?,?,?,?)"); $result = $query->execute(array($ownerFilename, $timestamp, $ownerLocation, $owner)); if (!$result) { - \OC_Log::write('files_trashbin', 'trash bin database couldn\'t be updated for the files owner', \OC_log::ERROR); + \OCP\Util::writeLog('files_trashbin', 'trash bin database couldn\'t be updated for the files owner', \OC_log::ERROR); } } } @@ -216,7 +216,7 @@ class Trashbin { if ($trashStorage->file_exists($trashInternalPath)) { $trashStorage->unlink($trashInternalPath); } - \OC_Log::write('files_trashbin', 'Couldn\'t move ' . $file_path . ' to the trash bin', \OC_log::ERROR); + \OCP\Util::writeLog('files_trashbin', 'Couldn\'t move ' . $file_path . ' to the trash bin', \OC_log::ERROR); } if ($sourceStorage->file_exists($sourceInternalPath)) { // failed to delete the original file, abort @@ -231,7 +231,7 @@ class Trashbin { $query = \OC_DB::prepare("INSERT INTO `*PREFIX*files_trash` (`id`,`timestamp`,`location`,`user`) VALUES (?,?,?,?)"); $result = $query->execute(array($filename, $timestamp, $location, $user)); if (!$result) { - \OC_Log::write('files_trashbin', 'trash bin database couldn\'t be updated', \OC_log::ERROR); + \OCP\Util::writeLog('files_trashbin', 'trash bin database couldn\'t be updated', \OC_log::ERROR); } \OCP\Util::emitHook('\OCA\Files_Trashbin\Trashbin', 'post_moveToTrash', array('filePath' => \OC\Files\Filesystem::normalizePath($file_path), 'trashPath' => \OC\Files\Filesystem::normalizePath($filename . '.d' . $timestamp))); @@ -358,7 +358,7 @@ class Trashbin { if ($timestamp) { $location = self::getLocation($user, $filename, $timestamp); if ($location === false) { - \OC_Log::write('files_trashbin', 'trash bin database inconsistent!', \OC_Log::ERROR); + \OCP\Util::writeLog('files_trashbin', 'trash bin database inconsistent!', \OCP\Util::ERROR); } else { // if location no longer exists, restore file in the root directory if ($location !== '/' && @@ -675,7 +675,7 @@ class Trashbin { foreach ($files as $file) { if ($availableSpace < 0) { $tmp = self::delete($file['name'], $user, $file['mtime']); - \OC_Log::write('files_trashbin', 'remove "' . $file['name'] . '" (' . $tmp . 'B) to meet the limit of trash bin size (50% of available quota)', \OC_log::INFO); + \OCP\Util::writeLog('files_trashbin', 'remove "' . $file['name'] . '" (' . $tmp . 'B) to meet the limit of trash bin size (50% of available quota)', \OC_log::INFO); $availableSpace += $tmp; $size += $tmp; } else { @@ -704,7 +704,7 @@ class Trashbin { if ($timestamp <= $limit) { $count++; $size += self::delete($filename, $user, $timestamp); - \OC_Log::write('files_trashbin', 'remove "' . $filename . '" from trash bin because it is older than ' . $retention_obligation, \OC_log::INFO); + \OCP\Util::writeLog('files_trashbin', 'remove "' . $filename . '" from trash bin because it is older than ' . $retention_obligation, \OCP\Util::INFO); } else { break; } diff --git a/apps/files_trashbin/list.php b/apps/files_trashbin/list.php index 68602ef8d8a..890f03aa09a 100644 --- a/apps/files_trashbin/list.php +++ b/apps/files_trashbin/list.php @@ -2,7 +2,6 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_trashbin/tests/trashbin.php b/apps/files_trashbin/tests/trashbin.php index 5535b3315bc..299c45b19a7 100644 --- a/apps/files_trashbin/tests/trashbin.php +++ b/apps/files_trashbin/tests/trashbin.php @@ -1,6 +1,7 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Clark Tomlinson <fallen013@gmail.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> |