]> source.dussan.org Git - nextcloud-server.git/commitdiff
l10n support enhanced in core
authorThomas Mueller <thomas.mueller@tmit.eu>
Thu, 7 Feb 2013 15:49:36 +0000 (16:49 +0100)
committerThomas Mueller <thomas.mueller@tmit.eu>
Thu, 7 Feb 2013 15:49:36 +0000 (16:49 +0100)
core/ajax/vcategories/add.php
core/ajax/vcategories/removeFromFavorites.php

index 23d00af70ab8c185ae44ab4780b9bdebf5d5dff3..16a1461be08b23c57fd00fc4ec9e15d8aa7b5acb 100644 (file)
@@ -34,7 +34,7 @@ debug(print_r($category, true));
 
 $categories = new OC_VCategories($type);
 if($categories->hasCategory($category)) {
-       bailOut(OC_Contacts_App::$l10n->t('This category already exists: '.$category));
+       bailOut($l->t('This category already exists: %s', array($category)));
 } else {
        $categories->add($category, true);
 }
index ba6e95c249735d3aeed236c6a7cfb2340b5164e6..78a528caa861b1ed474c3196512778e66d9e1f07 100644 (file)
@@ -27,12 +27,12 @@ if(is_null($type)) {
 }
 
 if(is_null($id)) {
-       bailOut($l->t('%s ID not provided.', $type));
+       bailOut($l->t('%s ID not provided.', array($type)));
 }
 
 $categories = new OC_VCategories($type);
 if(!$categories->removeFromFavorites($id, $type)) {
-       bailOut($l->t('Error removing %s from favorites.', $id));
+       bailOut($l->t('Error removing %s from favorites.', array($id)));
 }
 
 OC_JSON::success();