fix: sync rust api-server runtime and bindings
This commit is contained in:
@@ -9,8 +9,7 @@ use module_auth::{
|
||||
};
|
||||
use serde_json::json;
|
||||
use shared_contracts::auth::{
|
||||
AuthUserPayload, PhoneLoginRequest, PhoneLoginResponse, PhoneSendCodeRequest,
|
||||
PhoneSendCodeResponse,
|
||||
PhoneLoginRequest, PhoneLoginResponse, PhoneSendCodeRequest, PhoneSendCodeResponse,
|
||||
};
|
||||
use time::OffsetDateTime;
|
||||
use tracing::{info, warn};
|
||||
@@ -20,6 +19,7 @@ use crate::{
|
||||
auth_session::{
|
||||
attach_set_cookie_header, build_refresh_session_cookie_header, create_auth_session,
|
||||
},
|
||||
auth_payload::map_auth_user_payload,
|
||||
http_error::AppError,
|
||||
request_context::RequestContext,
|
||||
session_client::resolve_session_client_context,
|
||||
@@ -166,15 +166,7 @@ pub async fn phone_login(
|
||||
Some(&request_context),
|
||||
PhoneLoginResponse {
|
||||
token: signed_session.access_token,
|
||||
user: AuthUserPayload {
|
||||
id: result.user.id,
|
||||
username: result.user.username,
|
||||
display_name: result.user.display_name,
|
||||
phone_number_masked: result.user.phone_number_masked,
|
||||
login_method: result.user.login_method.as_str().to_string(),
|
||||
binding_status: result.user.binding_status.as_str().to_string(),
|
||||
wechat_bound: result.user.wechat_bound,
|
||||
},
|
||||
user: map_auth_user_payload(result.user),
|
||||
},
|
||||
),
|
||||
))
|
||||
|
||||
Reference in New Issue
Block a user