Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User routes update #537

Merged
merged 36 commits into from
Sep 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
7db5015
feat: Add UserProfile and other types
kozabrada123 Jul 28, 2024
20bdb32
api: re-do a large part of the users api
kozabrada123 Jul 28, 2024
62d48d6
feat: add modify user profile
kozabrada123 Jul 29, 2024
5d0a65a
feat: delete and disable user endpoints
kozabrada123 Jul 29, 2024
0a1c51d
feat: modify email and verify email endpoints
kozabrada123 Jul 29, 2024
e6a4cc3
feat!: add discriminator parameter to get_user_by_username
kozabrada123 Aug 8, 2024
1fa84b4
feat!: add get_user_profile query string schema
kozabrada123 Aug 8, 2024
80c9975
chore: add integration expire behavior
kozabrada123 Aug 8, 2024
926f89e
feat: add get_pomelo_suggestions and get_pomelo_eligibility
kozabrada123 Aug 8, 2024
7683ce4
feat: add create_pomelo_migration
kozabrada123 Aug 8, 2024
754c212
Merge dev into user-routes
kozabrada123 Aug 9, 2024
fa70c55
fix: rustdoc lints
kozabrada123 Aug 9, 2024
9d84790
feat: recent_mentions endpoints
kozabrada123 Aug 9, 2024
87aad46
feat: add get_user_harvest & create_user_harvest
kozabrada123 Aug 9, 2024
1dfbd21
feat: user notes endpoints
kozabrada123 Aug 9, 2024
6c6a87c
feat: add #545 and #546
kozabrada123 Aug 9, 2024
170f79b
feat: add authorize_connection
kozabrada123 Aug 10, 2024
a1caa38
feat: add rest* of Connections api
kozabrada123 Aug 13, 2024
f966a78
feat: add connected_accounts to UserProfile
kozabrada123 Aug 13, 2024
e06bc14
feat: add affinities
kozabrada123 Aug 13, 2024
9a4c9bc
feat: add get_premium_usage endpoint
kozabrada123 Aug 16, 2024
38d5fff
cliipy my arch nemesis strikes again
kozabrada123 Aug 16, 2024
b7d5497
aa
kozabrada123 Aug 16, 2024
2f4198c
feat: add create_domain_connection
kozabrada123 Aug 18, 2024
7e2e859
feat: add get_burst_credits
kozabrada123 Aug 18, 2024
f63c6a7
grumble grumble
kozabrada123 Aug 18, 2024
e0ae1a9
clippy
kozabrada123 Aug 18, 2024
28e3f21
fix READY deserialization error on spacebar
kozabrada123 Aug 18, 2024
fa859f6
fix a deserialization error on Spacebar
kozabrada123 Aug 18, 2024
ade43f2
skip serializing None query parameters
kozabrada123 Aug 18, 2024
2f24074
add test for get_user_profile
kozabrada123 Aug 18, 2024
a9b1a61
apparently Sb does not implement users/@me/notes
kozabrada123 Aug 21, 2024
53f08ff
add some tests, minor connection updates
kozabrada123 Aug 21, 2024
81b1525
Merge branch 'dev' into user-routes
kozabrada123 Aug 29, 2024
e0073fb
minor pre merge changes
kozabrada123 Sep 27, 2024
3fe7c21
Merge branch 'dev' into user-routes
kozabrada123 Sep 27, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/api/auth/login.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ impl Instance {
user.set_token(&login_result.token);
user.settings = login_result.settings;

let object = User::get(&mut user, None).await?;
let object = User::get_current(&mut user).await?;
*user.object.write().unwrap() = object;

let mut identify = GatewayIdentifyPayload::common();
Expand Down
2 changes: 1 addition & 1 deletion src/api/auth/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ impl Instance {
pub async fn login_with_token(&mut self, token: &str) -> ChorusResult<ChorusUser> {
let mut user = ChorusUser::shell(Arc::new(RwLock::new(self.clone())), token).await;

let object = User::get(&mut user, None).await?;
let object = User::get_current(&mut user).await?;
let settings = User::get_settings(&mut user).await?;

*user.object.write().unwrap() = object;
Expand Down
3 changes: 2 additions & 1 deletion src/api/auth/register.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,10 @@ impl Instance {
.deserialize_response::<Token>(&mut user)
.await?
.token;

user.set_token(&token);

let object = User::get(&mut user, None).await?;
let object = User::get_current(&mut user).await?;
let settings = User::get_settings(&mut user).await?;

*user.object.write().unwrap() = object;
Expand Down
Loading