diff options
author | Thomas Mueller <thomas.mueller@tmit.eu> | 2013-02-07 16:31:04 +0100 |
---|---|---|
committer | Thomas Mueller <thomas.mueller@tmit.eu> | 2013-02-07 16:31:04 +0100 |
commit | 18a288a3c3612db731e13d38da5786e622d6e9ec (patch) | |
tree | dc9797412be30520d3a7615fcef07ca63ee267c1 /apps/files_trashbin/ajax | |
parent | 488ab0dba2bc6d48968255943edaef7174757308 (diff) | |
download | nextcloud-server-18a288a3c3612db731e13d38da5786e622d6e9ec.tar.gz nextcloud-server-18a288a3c3612db731e13d38da5786e622d6e9ec.zip |
l10n support enhanced in files_trashbin
Diffstat (limited to 'apps/files_trashbin/ajax')
-rw-r--r-- | apps/files_trashbin/ajax/delete.php | 3 | ||||
-rw-r--r-- | apps/files_trashbin/ajax/undelete.php | 6 |
2 files changed, 6 insertions, 3 deletions
diff --git a/apps/files_trashbin/ajax/delete.php b/apps/files_trashbin/ajax/delete.php index 7ea0155724f..7a6bd1342ea 100644 --- a/apps/files_trashbin/ajax/delete.php +++ b/apps/files_trashbin/ajax/delete.php @@ -18,6 +18,7 @@ if ($path_parts['dirname'] == '.') { if (OCA\Files_Trashbin\Trashbin::delete($filename, $timestamp)) { OCP\JSON::success(array("data" => array("filename" => $file))); } else { - OCP\JSON::error(array("data" => array("message" => "Couldn't delete ".$file. " permanently"))); + $l = OC_L10N::get('files_trashbin'); + OCP\JSON::error(array("data" => array("message" => $l->t("Couldn't delete %s permanently", array($file))))); } diff --git a/apps/files_trashbin/ajax/undelete.php b/apps/files_trashbin/ajax/undelete.php index a118d003de7..cc010979c51 100644 --- a/apps/files_trashbin/ajax/undelete.php +++ b/apps/files_trashbin/ajax/undelete.php @@ -37,8 +37,10 @@ if ( $error ) { foreach ( $error as $e ) { $filelist .= $e.', '; } - OCP\JSON::error(array("data" => array("message" => "Couldn't restore ".rtrim($filelist,', '), "success" => $success, "error" => $error))); + $l = OC_L10N::get('files_trashbin'); + $message = $l->t("Couldn't restore %s", array(rtrim($filelist,', '))); + OCP\JSON::error(array("data" => array("message" => $message, + "success" => $success, "error" => $error))); } else { OCP\JSON::success(array("data" => array("success" => $success))); } - |