diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2015-12-01 14:23:00 +0100 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2015-12-01 14:23:00 +0100 |
commit | 490e01e3836b4a7d21ec660350d0401136985a49 (patch) | |
tree | e0bf2228c6655385b7cb507e27080e0990b87206 | |
parent | cce053f7e935cdb8a94eccc3d23775efa5f0699f (diff) | |
parent | 1761fdd9eea8fa8a367a45df3912943a4d67bf37 (diff) | |
download | nextcloud-server-490e01e3836b4a7d21ec660350d0401136985a49.tar.gz nextcloud-server-490e01e3836b4a7d21ec660350d0401136985a49.zip |
Merge pull request #20861 from owncloud/systemtags-better-exceptions-docs
Fix the docs of the exceptions and remove hardcoded language from the…
-rw-r--r-- | lib/private/systemtag/systemtagmanager.php | 4 | ||||
-rw-r--r-- | lib/public/systemtag/isystemtagmanager.php | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/lib/private/systemtag/systemtagmanager.php b/lib/private/systemtag/systemtagmanager.php index 95b9a61ca38..3cc45fc9524 100644 --- a/lib/private/systemtag/systemtagmanager.php +++ b/lib/private/systemtag/systemtagmanager.php @@ -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; diff --git a/lib/public/systemtag/isystemtagmanager.php b/lib/public/systemtag/isystemtagmanager.php index 2020ec52900..ffdaf03879e 100644 --- a/lib/public/systemtag/isystemtagmanager.php +++ b/lib/public/systemtag/isystemtagmanager.php @@ -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 */ |