Skip to content

Commit

Permalink
ref: add override_verified_type in fetch request
Browse files Browse the repository at this point in the history
  • Loading branch information
irisdv committed Nov 6, 2023
1 parent f6ac418 commit 3a4b90a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/endpoints/achievements/fetch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ pub async fn handler(
"category_img_url": "$img_url",
"category_type": "$type",
"category_disabled": "$disabled",
"category_override_verified_type": "$override_verified_type",
"achievements": {
"id": "$achievement.id",
"name": "$achievement.name",
Expand Down Expand Up @@ -91,6 +92,7 @@ pub async fn handler(
"category_img_url": "$category_img_url",
"category_type": "$category_type",
"category_disabled": "$category_disabled",
"category_override_verified_type": "$category_override_verified_type",
},
"achievements": { "$push": "$achievements" }
}
Expand All @@ -103,6 +105,7 @@ pub async fn handler(
"category_img_url": "$_id.category_img_url",
"category_type": "$_id.category_type",
"category_disabled": "$_id.category_disabled",
"category_override_verified_type": "$_id.category_override_verified_type",
"achievements": 1,
"_id": 0
}
Expand Down
1 change: 1 addition & 0 deletions src/models.rs
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ pub struct UserAchievements {
category_type: String,
#[serde(default = "default_category_disabled")]
pub category_disabled: bool,
pub category_override_verified_type: Option<String>,
achievements: Vec<UserAchievement>,
}

Expand Down

0 comments on commit 3a4b90a

Please sign in to comment.