Commit 44498c32 authored by Denis Arh's avatar Denis Arh
Browse files

Fix missing (super)user on provision

parent b4801073
......@@ -143,6 +143,15 @@ func (svc user) FindByID(ID uint64) (*types.User, error) {
return nil, ErrInvalidID.withStack()
}
tmp := internalAuth.NewIdentity(ID)
if internalAuth.IsSuperUser(tmp) {
// Handling case when looking for a super-user
//
// Currently, superuser is a virtual entity
// and does not exists in the db
return &types.User{ID: ID}, nil
}
return svc.proc(svc.user.FindByID(ID))
}
......
Markdown is supported
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