Commit Graph

454 Commits

Author SHA1 Message Date
rinpatch
4baea6e6d9 Fix leaking private configuration parameters in Mastodon and Twitter APIs, and add new configuration parameters to Mastodon API
This patch:
- Fixes `rights` in twitterapi ignoring `show_role`
- Fixes exposing default scope of the user to anyone in Mastodon API
- Extends Mastodon API to be able to show and set `no_rich_text`, `default_scope`, `hide_follows`, `hide_followers`, `hide_favorites` (requested by the FE in #674)

Sorry in advance for 500 line one commit diff, I should have split it up to separate MRs
2019-04-24 20:01:42 +03:00
Sachin Joshi
963d5774af fix the status notification with special char 2019-04-24 07:06:17 +05:45
Egor
b9cdf6d3b9 Use User.get_cached* everywhere 2019-04-22 07:20:43 +00:00
Alexander Strizhakov
88f0be9693 Feature/826 healthcheck endpoint 2019-04-22 07:19:53 +00:00
Egor Kislitsyn
e8c2f9a73a Merge remote-tracking branch 'pleroma/develop' into feature/disable-account 2019-04-22 13:08:30 +07:00
Ekaterina Vaartis
aef3a3ca46 Fix tests that used finmoji 2019-04-20 11:34:00 +03:00
rinpatch
e7c3c36766 Update functions in object fetcher for tesla and set up a proper mock for tests 2019-04-17 14:21:39 +03:00
rinpatch
627e5a0a49 Merge branch 'develop' into feature/database-compaction 2019-04-17 12:22:32 +03:00
kaniini
73df3046e0 Merge branch 'feature/788-separate-email-addresses' into 'develop'
Feature/788 separate email addresses

Closes #788

See merge request pleroma/pleroma!1040
2019-04-16 18:44:07 +00:00
Normandy
d4a749cfb2 Handle new-style mastodon follow lists
Fixes https://git.pleroma.social/pleroma/pleroma/issues/814
2019-04-16 18:35:38 +00:00
rinpatch
5d73dca064 Remove inReplyToStatusId 2019-04-15 11:50:36 +03:00
Alex S
c5d0fffeaf naming fix 2019-04-13 14:55:42 +07:00
lambda
184ae60b21 Merge branch 'bugfix/pleroma-email-naming' into 'develop'
Make the filename and module name of Pleroma.Emails.* orthogonal

See merge request pleroma/pleroma!1029
2019-04-12 10:41:09 +00:00
Egor Kislitsyn
d0304b4f92 more tests 2019-04-12 16:51:28 +07:00
Alex S
fe511a6c65 Merge branch 'develop' into feature/788-separate-email-addresses 2019-04-10 18:06:54 +07:00
Alex S
fe13a1d78c adding notify_email setting for trigger emails 2019-04-10 17:57:41 +07:00
lambda
e5d553aa45 Merge branch 'feature/767-multiple-use-invite-token' into 'develop'
Feature/767 multiple use invite token

See merge request pleroma/pleroma!1032
2019-04-10 10:10:08 +00:00
lambda
c8440b5e0c Merge branch 'fix/emoji-api-nonsense' into 'develop'
Change response format of /api/pleroma/emoji so it makes sense

See merge request pleroma/pleroma!1038
2019-04-10 06:22:51 +00:00
Haelwenn (lanodan) Monnier
9c1b36856b
s/Pleroma.UserEmail/Pleroma.Emails.UserEmail/ 2019-04-10 06:33:20 +02:00
kaniini
97395e013e Merge branch 'notification-pleroma-settings' into 'develop'
Notification controls

Closes #738

See merge request pleroma/pleroma!988
2019-04-10 02:10:31 +00:00
rinpatch
b57b43027c Change response format of /api/pleroma/emoji to the one that actually makes sense 2019-04-09 23:20:31 +03:00
Alex S
fee50636d0 removing not needed invite update 2019-04-08 20:08:16 +07:00
Alex S
012bb5dcc9 renaming expire_at -> expires_at
keyword style change
2019-04-08 16:01:28 +07:00
Alex S
47b07cec49 token -> invite renaming 2019-04-06 20:24:22 +07:00
Alex S
be54e40890 twitter api registration
fix for twitter api tests
2019-04-06 17:18:59 +07:00
Alex S
fa8483cb80 Merging develop into feature/770-add-emoji-tags
Conflict test/web/twitter_api/util_controller_test.exs
2019-04-02 20:39:52 +07:00
lambda
180b87257c Merge branch 'bugfix/share-mastodon' into 'develop'
[OStatus] adds status to pleroma instance if the url given is a status

See merge request pleroma/pleroma!1002
2019-04-02 12:47:40 +00:00
Alex S
9e0567ec52 Merge develop into feature/770-add-emoji-tags 2019-04-02 19:16:29 +07:00
Egor Kislitsyn
20c619f85f replace Repo.get_by(User, nickname: nickname) with User.get_by_nickname(nickname) in tests 2019-04-02 17:58:32 +07:00
Egor Kislitsyn
9a59c26619 replace Repo.get_by(User, ap_id: ap_id) with User.get_by_ap_id(ap_id) 2019-04-02 17:47:52 +07:00
Egor Kislitsyn
11c2d6bdc4 change Repo.get(Activity, id) => Activity.get_by_id(id) in tests 2019-04-02 17:08:03 +07:00
Egor Kislitsyn
1b3d921921 change Repo.get(User, id) => User.get_by_id(id) 2019-04-02 17:01:26 +07:00
Sachin Joshi
6386c1c9c1 fetch url for OStatus to know if it is a/c or status 2019-04-02 10:26:09 +05:45
Sachin Joshi
1d01e8e656 [OStatus] adds status to pleroma instance if the url given is a status 2019-04-01 22:26:58 +05:45
Alex S
3601f03147 Adding tag to emoji ets table
changes in apis
2019-04-01 17:17:57 +07:00
eugenijm
cd90695a34 Add PUT /api/pleroma/notification_settings endpoint 2019-03-28 18:55:16 +03:00
rinpatch
aacdcac1be Credo is upset about me not remembering the alphabet 2019-03-26 17:35:45 +03:00
rinpatch
087662d4fb Fix formatting 2019-03-26 17:18:18 +03:00
rinpatch
406d19331f Remove ActivityRepresenter 2019-03-26 17:16:21 +03:00
kaniini
1c3d3d0c2b Merge branch 'safe-mentions' into 'develop'
Add safe dm mode option.

See merge request pleroma/pleroma!958
2019-03-22 00:50:24 +00:00
William Pitcock
a223e65f35 tests: fixup 2019-03-21 23:56:57 +00:00
William Pitcock
fea3696799 common api: move context functions from twitterapi 2019-03-21 23:24:04 +00:00
lain
bf27190f7f UtilController: Return state of safe dm mentions. 2019-03-21 16:20:58 +01:00
Fong-Wan Chau
4ed2618f6c Allow 'rel' attribute on <a> link with specific values (for hashtag recognition). 2019-03-17 11:03:19 -04:00
eugenijm
43fb03be5a Allow to mark a single notification as read 2019-03-15 23:56:14 +03:00
Haelwenn (lanodan) Monnier
23960309a0
[Credo] Change quoted string with 3+ quotes to sigils 2019-03-13 04:26:56 +01:00
Haelwenn (lanodan) Monnier
c42d34b2ec
[Credo] fix Credo.Check.Readability.MaxLineLength 2019-03-13 04:26:56 +01:00
Haelwenn (lanodan) Monnier
a3a9cec483
[Credo] fix Credo.Check.Readability.AliasOrder 2019-03-13 04:26:54 +01:00
Haelwenn (lanodan) Monnier
6c8743d0c0
[Credo] Fix the warnings 2019-03-13 04:17:30 +01:00
eugenijm
86e4b48a5e Fix DM visibility for blocking users 2019-03-04 06:24:27 +03:00
eugenijm
d5418e9ff7 Remove follow_request_count as it's not needed for FE anymore.
MastoFE uses `GET /api/v1/follow_requests` and PleromaFE uses
`GET /api/pleroma/friend_requests` which they query on the initial page
load.
2019-03-03 18:42:27 +03:00
lambda
9b63fda9c7 Merge branch 'fix/dont-show-dms-in-mentions-timeline' into 'develop'
[#675] Do not show DMs in mentions timeline

See merge request pleroma/pleroma!877
2019-03-03 11:13:59 +00:00
rinpatch
9c6abec4d8 use commonapi.post instead of activitybulder 2019-03-01 15:48:04 +03:00
rinpatch
1341ee650e [#675] Do not show DMs in mentions timeline 2019-03-01 09:37:29 +03:00
kaniini
cf426a719d Merge branch 'with-mutes' into 'develop'
Add `with_muted` param.

Closes #683

See merge request pleroma/pleroma!872
2019-02-28 10:22:19 +00:00
eugenijm
6b11011039 Added deactivated to the user view 2019-02-28 09:08:34 +03:00
lain
bbbdbec4fd Remove parts of the old activity view.
Not used anymore.
2019-02-27 17:24:51 +01:00
lain
9ade1242c2 Add user muted status info to twitterapi. 2019-02-27 16:52:03 +01:00
Ivan Tashkinov
337367d764 [#468] More OAuth scopes-specific tests. 2019-02-20 12:27:28 +03:00
Ivan Tashkinov
04ee877a20 [#468] Added OAuth scopes-specific tests. 2019-02-19 22:28:21 +03:00
kaniini
7456338ed3 Merge branch 'feature/add-oauth-tokens-endpoint' into 'develop'
Add OAuth tokens endpoint

See merge request pleroma/pleroma!805
2019-02-18 04:02:41 +00:00
kaniini
cd019a5927 Merge branch 'follow-request-count' into 'develop'
Follow request count

See merge request pleroma/pleroma!817
2019-02-18 04:01:26 +00:00
Maxim Filippov
fd17a0cc9b Fix test 2019-02-18 00:10:48 +03:00
lain
38e15930cb Add option to return all friends in twitter api.
Mainly useful for user export.
2019-02-16 17:01:15 +01:00
eugenijm
ecdf0657ba Add logic for keeping follow_request_count up-to-date on the follow,
`approve_friend_request`, and `deny_friend_request` actions.
Add follow_request_count to the user view.
2019-02-15 12:20:20 +03:00
Maxim Filippov
62a45bdc11 Add revoke token 2019-02-13 12:59:56 +03:00
Maxim Filippov
61a4bc5095 Add OAuth tokens endpoint 2019-02-13 12:59:56 +03:00
Haelwenn (lanodan) Monnier
8bb7e19b38
test: de-group alias/es 2019-02-11 03:44:15 +01:00
Mark Felder
74518d0b60 hide_followings was renamed to hide_followers in the FE, but never synced up in the BE
This was a dirty regex replace which worked on my server
2019-02-06 22:34:44 +00:00
eugenijm
035eaeb9b8 Allow to configure visibility for admin and moderator badges 2019-02-06 06:18:05 +03:00
eugenijm
398c81f9c8 Add is_admin and is_moderator boolean fields to the user view 2019-02-06 02:10:06 +03:00
William Pitcock
73e6a1f1dd test: twitterapi: fix another possible test failure case 2019-02-05 20:08:16 +00:00
kaniini
eb2b1960e0 Merge branch 'feature/split-hide-network-v2' into 'develop'
Split hide_network into hide_followers & hide_followings (fixed)

See merge request pleroma/pleroma!765
2019-02-05 18:56:59 +00:00
William Pitcock
c4d317ccb6 test: twitterapi: fix the test breakage for real 2019-02-05 18:49:02 +00:00
Maxim Filippov
16ce129e38 Split hide_network into hide_followers & hide_followings (fixed) 2019-02-03 21:55:04 +03:00
lain
505a084058 Still do caching in tests. 2019-02-03 18:28:14 +01:00
kaniini
486749064f Revert "Merge branch 'feature/split-hide-network' into 'develop'"
This reverts merge request !733
2019-02-01 20:22:58 +00:00
kaniini
0a82a7e6d6 Merge branch 'feature/split-hide-network' into 'develop'
Split hide_network into hide_followers & hide_followings

See merge request pleroma/pleroma!733
2019-02-01 17:05:29 +00:00
kaniini
d03a116654 Merge branch 'hj-happiness-improvement' into 'develop'
New frontend configuration mechanism.

Closes #445

See merge request pleroma/pleroma!700
2019-01-29 13:54:10 +00:00
Maxim Filippov
3e968f9ef2 Format 2019-01-28 21:40:08 +03:00
Maxim Filippov
50d6183893 Split hide_network into hide_followers & hide_followings 2019-01-28 21:40:08 +03:00
lain
8e8a1e1ba8 Return new-style config if old-style config is set to false.
This is in preparation for 1.0. We'll be able to switch the config to the new
mechanism on PleromaFE then as well.
2019-01-28 13:07:12 +01:00
William Pitcock
020b3b29d9 test: update twitterapi tests 2019-01-28 05:53:17 +00:00
kaniini
4df71cd88b Merge branch 'classic-flakeids' into 'develop'
Flake Ids for Users and Activities

Closes #450

See merge request pleroma/pleroma!645
2019-01-25 04:59:06 +00:00
Maxim Filippov
4333fea1dc Send "hide_network" in user_view 2019-01-23 19:47:51 +03:00
lain
e221c681dc New frontend configuration mechanism. 2019-01-23 12:40:57 +01:00
href
28d77e373c
Flake Ids for Users and Activities 2019-01-23 11:26:27 +01:00
Haelwenn (lanodan) Monnier
98c8184c1f
Activity: get_create_activity_by_object_ap_id/1 → get_create_by_object_ap_id/1 2019-01-21 08:00:41 +01:00
lambda
f3045a179e Merge branch 'i1t/pleroma-477_user_search_improvements' into 'develop'
I1t/pleroma 477 user search improvements

See merge request pleroma/pleroma!685
2019-01-20 10:24:05 +00:00
Ivan Tashkinov
ed8f55ab8e [#477] User: FTS and trigram search results mixing (to handle misspelled requests). 2019-01-18 10:35:45 +03:00
William Pitcock
85a5be6220 tests: fixup 2019-01-16 04:09:01 +00:00
Ivan Tashkinov
fc965f982c [#477] Added FTS index for users. Fixed failing test. 2019-01-15 12:04:54 +03:00
kaniini
11d08c6226 Merge branch 'twapi-follower-pagination' into 'develop'
Twapi follower pagination

See merge request pleroma/pleroma!648
2019-01-10 18:03:32 +00:00
kaniini
7f5efddd6e Merge branch 'feature/pinned-posts' into 'develop'
Pinned Statuses

Closes #440

See merge request pleroma/pleroma!636
2019-01-10 02:39:53 +00:00
lain
a99e156f2c Add integer casts. 2019-01-09 18:17:23 +01:00
lain
7ac152ed38 TwitterAPI: Add follower/following pagination. 2019-01-09 18:14:32 +01:00
lambda
1881680e28 Merge branch 'scarlett/pleroma-summary-html-api' into 'develop'
Scarlett/pleroma summary html api

See merge request pleroma/pleroma!647
2019-01-09 16:26:38 +00:00
lain
8df348a3da Add test for summary_html 2019-01-09 17:18:37 +01:00
Egor Kislitsyn
44a1e69484 Add Twitter API for the pinned statuses
```
# Only return statuses that have been pinned
GET /api/statuses/user_timeline.json?pinned=true

# Pin
POST /api/statuses/pin/:id

# Unpin
POST /api/statuses/unpin/:id
```
2019-01-09 19:54:19 +07:00
lain
a16b17cc61 Actually put some onformation in the error user, make it actually properly parse
in conversations.
2019-01-07 20:59:30 +01:00