forked from jmug/stoatchat
Fix: Handle status::User on group create.
This commit is contained in:
@@ -38,8 +38,12 @@ pub async fn req(user: User, info: Json<Data>) -> Result<JsonValue> {
|
||||
}
|
||||
|
||||
for target in &set {
|
||||
if get_relationship(&user, target) != RelationshipStatus::Friend {
|
||||
Err(Error::NotFriends)?
|
||||
match get_relationship(&user, target) {
|
||||
RelationshipStatus::Friend |
|
||||
RelationshipStatus::User => {},
|
||||
_ => {
|
||||
return Err(Error::NotFriends);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1 +1 @@
|
||||
pub const VERSION: &str = "0.5.0-alpha.0-patch.0";
|
||||
pub const VERSION: &str = "0.5.0-alpha.1";
|
||||
|
||||
Reference in New Issue
Block a user