]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix the docs of the exceptions and remove hardcoded language from the message
authorJoas Schilling <nickvergessen@owncloud.com>
Tue, 1 Dec 2015 11:32:50 +0000 (12:32 +0100)
committerJoas Schilling <nickvergessen@owncloud.com>
Tue, 1 Dec 2015 11:32:50 +0000 (12:32 +0100)
lib/private/systemtag/systemtagmanager.php
lib/public/systemtag/isystemtagmanager.php

index 95b9a61ca38ccd7f29ae03e959982d653526b631..3cc45fc9524c325796e737172efa74e2a4f77b58 100644 (file)
@@ -94,9 +94,7 @@ class SystemTagManager implements ISystemTagManager {
                $result->closeCursor();
 
                if (count($tags) !== count($tagIds)) {
-                       throw new TagNotFoundException(
-                               'Tag(s) with id(s) ' . json_encode(array_diff($tagIds, array_keys($tags))) . ' not found'
-                       );
+                       throw new TagNotFoundException(json_encode(array_diff($tagIds, array_keys($tags))));
                }
 
                return $tags;
index 2020ec5290052a651a8fcd38afd689d89b29a89b..ffdaf03879ede4f057156e1094b22c0fd3d7d478 100644 (file)
@@ -35,7 +35,9 @@ interface ISystemTagManager {
         *
         * @return \OCP\SystemTag\ISystemTag[] array of system tags with tag id as key
         *
-        * @throws \OCP\SystemTag\TagNotFoundException if at least one given tag id did no exist
+        * @throws \InvalidArgumentException if at least one given tag ids is invalid (string instead of integer, etc.)
+        * @throws \OCP\SystemTag\TagNotFoundException if at least one given tag ids did no exist
+        *                      The message contains a json_encoded array of the ids that could not be found
         *
         * @since 9.0.0
         */