Fix de-syndication
This commit is contained in:
@@ -87,7 +87,6 @@ module Adamantium
|
|||||||
mastodon_server = settings.mastodon_server.split("@").first
|
mastodon_server = settings.mastodon_server.split("@").first
|
||||||
response = HTTParty.delete("#{mastodon_server}api/v1/statuses/#{post_id}", {
|
response = HTTParty.delete("#{mastodon_server}api/v1/statuses/#{post_id}", {
|
||||||
headers: {
|
headers: {
|
||||||
"Idempotency-Key": key,
|
|
||||||
Authorization: "Bearer #{mastodon_token}"
|
Authorization: "Bearer #{mastodon_token}"
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
@@ -13,7 +13,7 @@ module Admin
|
|||||||
|
|
||||||
request = if target.to_sym == :mastodon
|
request = if target.to_sym == :mastodon
|
||||||
masto_id = post.syndication_sources[target].split("/").last
|
masto_id = post.syndication_sources[target].split("/").last
|
||||||
if masto_id == ""
|
if masto_id.nil?
|
||||||
Success()
|
Success()
|
||||||
else
|
else
|
||||||
mastodon.de_syndicate(post_id: masto_id)
|
mastodon.de_syndicate(post_id: masto_id)
|
||||||
|
Reference in New Issue
Block a user