summaryrefslogtreecommitdiffstats
path: root/apps/files/ajax
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2013-02-07 23:57:18 +0100
committerRobin Appelman <icewind@owncloud.com>2013-02-07 23:57:18 +0100
commitb67251b0ffbba5d52802ced8e1ff02f408be8cc7 (patch)
treef1f72008b1ecaf6e3e1bae649a078b8414f9b28d /apps/files/ajax
parentfc7230349b6028184b21b229ef5873ea8b7aa99a (diff)
downloadnextcloud-server-b67251b0ffbba5d52802ced8e1ff02f408be8cc7.tar.gz
nextcloud-server-b67251b0ffbba5d52802ced8e1ff02f408be8cc7.zip
Files: add translation support back to move/rename
Diffstat (limited to 'apps/files/ajax')
-rw-r--r--apps/files/ajax/move.php6
-rw-r--r--apps/files/ajax/rename.php4
2 files changed, 5 insertions, 5 deletions
diff --git a/apps/files/ajax/move.php b/apps/files/ajax/move.php
index 78ed218c136..03d2a6a5624 100644
--- a/apps/files/ajax/move.php
+++ b/apps/files/ajax/move.php
@@ -12,7 +12,7 @@ $file = stripslashes($_POST["file"]);
$target = stripslashes(rawurldecode($_POST["target"]));
if(\OC\Files\Filesystem::file_exists($target . '/' . $file)) {
- OCP\JSON::error(array("data" => array( "message" => "Could not move $file - File with this name already exists" )));
+ OCP\JSON::error(array("data" => array( "message" => $l->t("Could not move %s - File with this name already exists", array($file)) )));
exit;
}
@@ -22,8 +22,8 @@ if ($dir != '' || $file != 'Shared') {
if(\OC\Files\Filesystem::rename($sourceFile, $targetFile)) {
OCP\JSON::success(array("data" => array( "dir" => $dir, "files" => $file )));
} else {
- OCP\JSON::error(array("data" => array( "message" => "Could not move $file" )));
+ OCP\JSON::error(array("data" => array( "message" => $l->t("Could not move %s", array($file)) )));
}
}else{
- OCP\JSON::error(array("data" => array( "message" => "Could not move $file" )));
+ OCP\JSON::error(array("data" => array( "message" => $l->t("Could not move %s", array($file)) )));
}
diff --git a/apps/files/ajax/rename.php b/apps/files/ajax/rename.php
index 970aaa638da..2364e477d93 100644
--- a/apps/files/ajax/rename.php
+++ b/apps/files/ajax/rename.php
@@ -17,8 +17,8 @@ if ( $newname !== '.' and ($dir != '' || $file != 'Shared') and $newname !== '.'
if(\OC\Files\Filesystem::rename($sourceFile, $targetFile)) {
OCP\JSON::success(array("data" => array( "dir" => $dir, "file" => $file, "newname" => $newname )));
} else {
- OCP\JSON::error(array("data" => array( "message" => "Unable to rename file" )));
+ OCP\JSON::error(array("data" => array( "message" => $l->t("Unable to rename file") )));
}
}else{
- OCP\JSON::error(array("data" => array( "message" => "Unable to rename file" )));
+ OCP\JSON::error(array("data" => array( "message" => $l->t("Unable to rename file") )));
}