Allow switching to current namespace when authenticated as a database user
This commit is contained in:
parent
eba00bbca3
commit
3b41217423
1 changed files with 1 additions and 0 deletions
|
@ -197,6 +197,7 @@ impl<'a> Executor<'a> {
|
|||
Auth::No => self.set_ns(&mut ctx, &mut opt, ns).await,
|
||||
Auth::Kv => self.set_ns(&mut ctx, &mut opt, ns).await,
|
||||
Auth::Ns(v) if v == ns => self.set_ns(&mut ctx, &mut opt, ns).await,
|
||||
Auth::Db(v, _) if v == ns => self.set_ns(&mut ctx, &mut opt, ns).await,
|
||||
_ => {
|
||||
opt.ns = None;
|
||||
return Err(Error::NsNotAllowed {
|
||||
|
|
Loading…
Reference in a new issue