revert OStatus xmlns to mastodon.social

This commit is contained in:
robcolbert
2019-07-06 21:57:50 -04:00
parent b4d3acc18a
commit 948ba449fb
6 changed files with 8 additions and 8 deletions

View File

@@ -90,7 +90,7 @@ class OStatus::Activity::Creation < OStatus::Activity::Base
end
def visibility_scope
@xml.at_xpath('./gabsocial:scope', gabsocial: OStatus::TagManager::GABSCL_XMLNS)&.content&.to_sym || :public
@xml.at_xpath('./gabsocial:scope', gabsocial: OStatus::TagManager::MTDN_XMLNS)&.content&.to_sym || :public
end
def published

View File

@@ -345,7 +345,7 @@ class OStatus::AtomSerializer
parent['xmlns:poco'] = OStatus::TagManager::POCO_XMLNS
parent['xmlns:media'] = OStatus::TagManager::MEDIA_XMLNS
parent['xmlns:ostatus'] = OStatus::TagManager::OS_XMLNS
parent['xmlns:gabsocial'] = OStatus::TagManager::GABSCL_XMLNS
parent['xmlns:gabsocial'] = OStatus::TagManager::MTDN_XMLNS
end
def serialize_status_attributes(entry, status)

View File

@@ -15,8 +15,8 @@ class OStatus::TagManager
authorize: 'http://activitystrea.ms/schema/1.0/authorize',
reject: 'http://activitystrea.ms/schema/1.0/reject',
unfollow: 'http://ostatus.org/schema/1.0/unfollow',
block: 'http://gab.com/schema/1.0/block',
unblock: 'http://gab.com/schema/1.0/unblock',
block: 'http://mastodon.social/schema/1.0/block',
unblock: 'http://mastodon.social/schema/1.0/unblock',
}.freeze
TYPES = {
@@ -39,7 +39,7 @@ class OStatus::TagManager
POCO_XMLNS = 'http://portablecontacts.net/spec/1.0'
DFRN_XMLNS = 'http://purl.org/macgirvin/dfrn/1.0'
OS_XMLNS = 'http://ostatus.org/schema/1.0'
GABSCL_XMLNS = 'http://gab.com/schema/1.0'
MTDN_XMLNS = 'http://mastodon.social/schema/1.0'
def unique_tag(date, id, type)
"tag:#{Rails.configuration.x.local_domain},#{date.strftime('%Y-%m-%d')}:objectId=#{id}:objectType=#{type}"