fix: don't show posts from private profiles when quoted
fix: password updating (mod)
This commit is contained in:
parent
2ec56809b8
commit
03b252937b
8 changed files with 87 additions and 36 deletions
|
@ -133,12 +133,13 @@ pub async fn update_user_password_request(
|
|||
None => return Json(Error::NotAllowed.into()),
|
||||
};
|
||||
|
||||
if user.id != id && !user.permissions.check(FinePermission::MANAGE_USERS) {
|
||||
let can_force = user.permissions.check(FinePermission::MANAGE_USERS);
|
||||
if user.id != id && !can_force {
|
||||
return Json(Error::NotAllowed.into());
|
||||
}
|
||||
|
||||
match data
|
||||
.update_user_password(id, req.from, req.to, user, false)
|
||||
.update_user_password(id, req.from, req.to, user, can_force)
|
||||
.await
|
||||
{
|
||||
Ok(_) => Json(ApiReturn {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue