From 86998f183d0363b165592d111325e1442dc7ac68 Mon Sep 17 00:00:00 2001 From: PARK BYUNG JUN Date: Wed, 21 Sep 2022 14:38:13 +0000 Subject: [PATCH] bug fixed --- src/api/game/api.rs | 2 +- src/services/game/service.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/api/game/api.rs b/src/api/game/api.rs index 422984c..3ed645d 100644 --- a/src/api/game/api.rs +++ b/src/api/game/api.rs @@ -143,7 +143,7 @@ impl Api { } let user_id = r.user_id.unwrap_or(0); - let url = r.url.unwrap_or("".to_string()); + let url = r.url.unwrap_or_else(|| "".to_string()); let balance = r.balance.unwrap_or(0.00); Ok(models::GetGameUrlResponse { diff --git a/src/services/game/service.rs b/src/services/game/service.rs index bbf4c66..f5bc6d6 100644 --- a/src/services/game/service.rs +++ b/src/services/game/service.rs @@ -290,7 +290,7 @@ impl Service { nickname: m.member.nickname.clone(), site_username: m.member.username.clone(), group_key: m.member.parent_member.map(|p| p.username.clone()), - amount: m.balance_sum, + amount: 0.0, request_key: None, }; let res = self.game_api.get_game_url(req).await.map_err(|e| {