]> git.mxchange.org Git - friendica.git/commitdiff
Update src/Module/Api/Mastodon/FollowedTags.php
authorMichael Vogel <icarus@dabo.de>
Mon, 28 Nov 2022 04:00:08 +0000 (05:00 +0100)
committerGitHub <noreply@github.com>
Mon, 28 Nov 2022 04:00:08 +0000 (05:00 +0100)
Co-authored-by: Hypolite Petovan <hypolite@mrpetovan.com>
src/Module/Api/Mastodon/FollowedTags.php

index 6e95783c9febf84aff8166c9a32eecda1437f87a..eb5e32fdc143c85264f6bea775e4db4e4471701c 100644 (file)
@@ -65,7 +65,7 @@ class FollowedTags extends BaseApi
                $saved_searches = DBA::select('search', ['id', 'term'], $condition);
                while ($saved_search = DBA::fetch($saved_searches)) {
                        self::setBoundaries($saved_search['id']);
-                       $tag = ['name' => substr($saved_search['term'], 1)];
+                       $tag = ['name' => ltrim($saved_search['term'], '#')];
 
                        $hashtag  = new \Friendica\Object\Api\Mastodon\Tag($this->baseUrl, $tag, [], true);
                        $return[] = $hashtag->toArray();