aboutsummaryrefslogtreecommitdiff
path: root/lib/pleroma/web/activity_pub/utils.ex
AgeCommit message (Collapse)Author
2022-08-09Object: remove context_id fieldHélène
30 to 70% of the objects in the object table are simple JSON objects containing a single field, 'id', being the context's ID. The reason for the creation of an object per context seems to be an old relic from the StatusNet era, and has only been used nowadays as an helper for threads in Pleroma-FE via the `pleroma.conversation_id` field in status views. An object per context was created, and its numerical ID (table column) was used and stored as 'context_id' in the object and activity along with the full 'context' URI/string. This commit removes this field and stops creation of objects for each context, which will also allow incoming activities to use activity IDs as contexts, something which was not possible before, or would have been very broken under most circumstances. The `pleroma.conversation_id` field has been reimplemented in a way to maintain backwards-compatibility by calculating a CRC32 of the full context URI/string in the object, instead of relying on the row ID for the created context object.
2022-02-25Copyright bump for 2022Sean King
2021-12-17Allow updating accepted follow activities in ↵Tusooa Zhu
Web.ActivityPub.Utils.update_follow_state_for_all/2 Mastodon uses the Reject activity also for the purpose of removing a follower, in addition to reject a follow request. We should also update the original Follow activity in this case.
2021-06-01Merge remote-tracking branch 'pleroma/develop' into cycles-constantsAlex Gleason
2021-06-01Merge branch 'cycles-base-url' into 'develop'feld
Deprecate Pleroma.Web.base_url/0 See merge request pleroma/pleroma!3432
2021-05-31Deprecate Pleroma.Web.base_url/0Alex Gleason
Use Pleroma.Web.Endpoint.url/0 directly instead. Reduces compiler cycles.
2021-05-31Pleroma.Constants.as_local_public/0 --> ↵Alex Gleason
Pleroma.Web.ActivityPub.Utils.as_local_public/0 Move as_local_public/0 to stop making modules depend on Web at compile-time
2021-04-05utils: Fix maybe_splice_recipient when "object" isn’t a mapHaelwenn (lanodan) Monnier
2021-04-05ActivityPubControllerTest: Apply same addr changes to objectHaelwenn (lanodan) Monnier
2021-01-13Bump Copyright to 2021Haelwenn (lanodan) Monnier
grep -rl '# Copyright © .* Pleroma' * | xargs sed -i 's;Copyright © .* Pleroma .*;Copyright © 2017-2021 Pleroma Authors <https://pleroma.social/>;'
2020-11-19test fixesAlexander Strizhakov
2020-11-19fix for mastodon forwarded reportsAlexander Strizhakov
2020-11-11Add `local` visibilityEgor Kislitsyn
2020-10-15Add local-only statusesEgor Kislitsyn
2020-07-23[#2791] AccountView: renamed `:force` option to `:skip_visibility_check`.Ivan Tashkinov
2020-07-22[#1973] Fixed accounts rendering in GET /api/v1/pleroma/chats with truish ↵Ivan Tashkinov
:restrict_unauthenticated. Made `Pleroma.Web.MastodonAPI.AccountView.render("show.json", _)` demand :for or :force option in order to prevent incorrect rendering of empty map instead of expected user representation with truish :restrict_unauthenticated setting.
2020-06-05Merge remote-tracking branch 'origin/develop' into ↵Egor Kislitsyn
activity-pub-use-atoms-as-keys
2020-06-05Create Pleroma.Maps.put_if_present(map, key, value, value_fun // &{:ok, &1})Haelwenn
Unifies all the similar functions to one and simplify some blocks with it.
2020-06-04Use atoms as keys in `ActivityPub.fetch_*` functions optionsEgor Kislitsyn
2020-06-03Add OpenAPI spec for AdminAPI.ReportControllerEgor Kislitsyn
2020-05-12ActivityPub: Fix non-federating blocks.lain
2020-05-07Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into ↵lain
feature/undo-validator-reduced
2020-05-05Undoing: Move undoing blocks to the pipeline everywhere.lain
2020-04-30Typo fix.lain
2020-03-30removing grouped reports admin api endpointAlexander Strizhakov
2020-03-22Mastodon API Account view: Remove an outdated hackrinpatch
The hack with caching the follow relationship was introduced when we still were storing it inside the follow activity, resulting in slow queries. Now we store follow state in `FollowRelationship` table, so this is no longer necessary.
2020-03-15rip out fetch_initial_postsrinpatch
Every time someone tries to use it, it goes mad and tries to scrape the entire fediverse for no visible reason, it's better to just remove it than continue shipping it in it's current state. idea acked by lain and feld on irc Closes #1595 #1422
2020-03-02Bump copyright years of files changed after 2020-01-07Haelwenn (lanodan) Monnier
Done via the following command: git diff fcd5dd259a1700a045be902b43391b0d1bd58a5b --stat --name-only | xargs sed -i '/Pleroma Authors/c# Copyright © 2017-2020 Pleroma Authors <https:\/\/pleroma.social\/>'
2020-02-25Fix Dialyzer warningsEgor Kislitsyn
2020-02-07Merge branch 'cancel-follow-request' into 'develop'Haelwenn
Add support for cancellation of a follow request Closes #1522 See merge request pleroma/pleroma!2175
2020-02-06EmojiReactions: Rename to EmojiReactsLain Soykaf
2020-02-05Add support for cancellation of a follow requestEgor Kislitsyn
2020-01-23Emoji reactions: Add sanity checks for the cachelain
2020-01-22Emoji reactions: Change cache and reply formatlain
2019-12-17Add ActivityPub Object Event type supportThomas Citharel
Adds Event support in the same way Video objects are handled, with the name of the object as message header. Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2019-12-12Merge branch 'develop' into feature/report-notesMaxim Filippov
2019-12-04Add report notesMaxim Filippov
2019-11-28Fetch account from report, not from status (it might be deleted)Maxim Filippov
2019-11-27Handle reopened reports with deleted statusesMaxim Filippov
2019-11-26Merge branch 'develop' into feature/admin-api-render-whole-statusMaxim Filippov
2019-11-26AdminAPI: Grouped reports old/new fixMaxim Filippov
If some status received reports both in the "new" format and "old" format it was considered reports on two different statuses (in the context of grouped reports)
2019-11-26AdminAPI: Fix grouped reports for closed/resolved reportsMaxim Filippov
2019-11-25Admin API: Render whole status in grouped reportsMaxim Filippov
2019-11-16Admin API: Error when trying to update reports in the "old" formatMaxim Filippov
2019-11-14Merge branch 'feature/reports-groups-and-multiple-state-update' into 'develop'feld
Admin API: Grouped reports, update multiple reports in one query Closes admin-fe#43 See merge request pleroma/pleroma!1815
2019-11-08Merge remote-tracking branch 'origin/develop' into reactionslain
2019-11-08Support old flag formatMaxim Filippov
2019-11-06Grouped reports with status data baked inMaxim Filippov
2019-11-05Merge branch 'develop' into feature/reports-groups-and-multiple-state-updateMaxim Filippov
2019-10-27Merge branch 'develop' into feature/store-statuses-data-inside-flagMaxim Filippov