]> git.mxchange.org Git - friendica-addons.git/blobdiff - tumblr/tumblr.php
Tumblr/Bluesky: Store the subscribed feed/tag
[friendica-addons.git] / tumblr / tumblr.php
index 78c7d3849342d9350a24b258bec79837893bdefa..a7a0db4c0657a3fe9bee56d79827a1a1ef3d0443 100644 (file)
@@ -734,6 +734,9 @@ function tumblr_fetch_tags(int $uid)
                        $id = tumblr_process_post($post, $uid, Item::PR_TAG);
                        if (!empty($id)) {
                                Logger::debug('Tag post imported', ['tag' => $tag, 'id' => $id]);
+                               $post = Post::selectFirst(['uri-id'], ['id' => $id]);
+                               $stored = Post\Category::storeFileByURIId($post['uri-id'], $uid, Post\Category::SUBCRIPTION, $tag);
+                               Logger::debug('Stored tag subscription for user', ['uri-id' => $post['uri-id'], 'uid' => $uid, 'tag' => $tag, 'stored' => $stored]);
                        }
                }
        }