Skip to content
This repository has been archived by the owner on May 27, 2024. It is now read-only.

Commit

Permalink
activitypub: remove _misskey_content attribute
Browse files Browse the repository at this point in the history
As already noted back in misskey-dev#8787
the intention was to replace the `_misskey_content` attribute with the
ActivityPub-defined `source` property. Misskey and by extension Foundkey
have shipped with the `source` property and the respective parsing for
quite a while so it seems reasonable to remove it now.

Changelog: Removed
  • Loading branch information
Johann150 committed Feb 11, 2023
1 parent 7c89e99 commit fff93c6
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 4 deletions.
2 changes: 0 additions & 2 deletions packages/backend/src/remote/activitypub/models/note.ts
Original file line number Diff line number Diff line change
Expand Up @@ -207,8 +207,6 @@ export async function createNote(value: string | IObject, resolver: Resolver, si
let text: string | null = null;
if (note.source?.mediaType === 'text/x.misskeymarkdown' && typeof note.source.content === 'string') {
text = note.source.content;
} else if (typeof note._misskey_content !== 'undefined') {
text = note._misskey_content;
} else if (typeof note.content === 'string') {
text = fromHtml(note.content, quote?.uri);
}
Expand Down
1 change: 0 additions & 1 deletion packages/backend/src/remote/activitypub/renderer/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ export const renderActivity = (x: any): IActivity | null => {
value: 'schema:value',
// Misskey
misskey: 'https://misskey-hub.net/ns#',
'_misskey_content': 'misskey:_misskey_content',
'_misskey_quote': 'misskey:_misskey_quote',
'_misskey_reaction': 'misskey:_misskey_reaction',
'_misskey_votes': 'misskey:_misskey_votes',
Expand Down
1 change: 0 additions & 1 deletion packages/backend/src/remote/activitypub/renderer/note.ts
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,6 @@ export default async function renderNote(note: Note, dive = true, isTalk = false
attributedTo,
summary,
content,
_misskey_content: text,
source: {
content: text,
mediaType: 'text/x.misskeymarkdown',
Expand Down

0 comments on commit fff93c6

Please sign in to comment.