1
0
mirror of https://github.com/owncloud/bookmarks.git synced 2025-03-10 10:29:20 +01:00

Merge pull request #287 from owncloud/fix-warning

fix undefined offset warning
This commit is contained in:
blizzz 2016-08-27 01:28:41 +02:00 committed by GitHub
commit 8a04a7bbff

View File

@ -43,9 +43,13 @@ class PublicController extends ApiController {
return $this->newJsonErrorMessage("User could not be identified"); return $this->newJsonErrorMessage("User could not be identified");
} }
if ($tags[0] == "") { if (!is_array($tags)) {
if(is_string($tags) && $tags !== '') {
$tags = [ $tags ];
} else {
$tags = array(); $tags = array();
} }
}
$public = true; $public = true;