There was an error while loading. Please reload this page.
1 parent 37a3a88 commit e523baeCopy full SHA for e523bae
1 file changed
fxtumblr/tumblr/types.py
@@ -255,7 +255,13 @@ def from_api(
255
256
# https://(username).tumblr.com/post/(id)/(slug)
257
elif "tumblr.com/post/" in data["parent_post_url"]:
258
- username, rest = data["parent_post_url"].split(".", 1)
+ username, rest = data["parent_post_url"][8:].split(".", 1)
259
+ post_id = int(rest.split("/")[2])
260
+ return cls(
261
+ blog=Blog.create_dummy(username),
262
+ post_id=post_id,
263
+ post_url=data["parent_post_url"],
264
+ )
265
266
# If there is no parent post URL, try to guess from last trail item
267
elif prefix == "reblogged_root" and data["trail"]:
0 commit comments