mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-11-27 06:41:18 +00:00
Merge branch 'dev'
This commit is contained in:
commit
ce0a924b66
1 changed files with 5 additions and 3 deletions
|
@ -305,10 +305,12 @@ fn parse_json_message(chat: &mut ChatServer, msg: StandardMessage) -> Result<Str
|
||||||
Ok(serde_json::to_string(&res)?)
|
Ok(serde_json::to_string(&res)?)
|
||||||
}
|
}
|
||||||
UserOperation::Register => {
|
UserOperation::Register => {
|
||||||
chat.check_rate_limit_register(msg.id)?;
|
|
||||||
let register: Register = serde_json::from_str(data)?;
|
let register: Register = serde_json::from_str(data)?;
|
||||||
let res = Oper::new(user_operation, register).perform()?;
|
let res = Oper::new(user_operation, register).perform();
|
||||||
Ok(serde_json::to_string(&res)?)
|
if res.is_ok() {
|
||||||
|
chat.check_rate_limit_register(msg.id)?;
|
||||||
|
}
|
||||||
|
Ok(serde_json::to_string(&res?)?)
|
||||||
}
|
}
|
||||||
UserOperation::GetUserDetails => {
|
UserOperation::GetUserDetails => {
|
||||||
let get_user_details: GetUserDetails = serde_json::from_str(data)?;
|
let get_user_details: GetUserDetails = serde_json::from_str(data)?;
|
||||||
|
|
Loading…
Reference in a new issue