pub struct UpdateUser(/* private fields */);Expand description
POST /admin/update-user: needs user:update, plus user:set-role for role,
user:ban for the ban columns and user:set-email for email and emailVerified.
Answers the user itself, unwrapped. Setting banned: true revokes the user’s sessions.
Trait Implementations§
Source§impl<D: Adapter> Endpoint<D> for UpdateUser
impl<D: Adapter> Endpoint<D> for UpdateUser
const METHOD: Method = Method::POST
const PATH: &'static str = "/admin/update-user"
type Access = MaybeAuthenticated
type Input = UpdateUserInput
type Output = UserView
async fn call( &self, ctx: Ctx<D, MaybeAuthenticated>, input: UpdateUserInput, ) -> Result<UserView, AuthError>
Auto Trait Implementations§
impl Forget for UpdateUser
impl Freeze for UpdateUser
impl Move for UpdateUser
impl RefUnwindSafe for UpdateUser
impl Send for UpdateUser
impl Sync for UpdateUser
impl Unpin for UpdateUser
impl UnsafeUnpin for UpdateUser
impl UnwindSafe for UpdateUser
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more