Skip to content
Snippets Groups Projects
Commit cb882ce1 authored by insert's avatar insert
Browse files

Block @revolt from being registered.

parent 5486a68b
Branches
No related merge requests found
Pipeline #507 passed with stage
in 2 minutes and 17 seconds
......@@ -27,6 +27,10 @@ pub async fn req(session: Session, user: Option<User>, data: Json<Data>) -> Resu
data.validate()
.map_err(|error| Error::FailedValidation { error })?;
if data.username == "revolt" {
Err(Error::UsernameTaken)?
}
let col = get_collection("users");
if col
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment