fix(vm/create): bad resource set condition (#647)
This commit is contained in:
parent
9158e33546
commit
8d2bbe86d5
@ -48,7 +48,7 @@ const extract = (obj, prop) => {
|
||||
export async function create (params) {
|
||||
const { user } = this
|
||||
const resourceSet = extract(params, 'resourceSet')
|
||||
if (resourceSet !== undefined && user.permission !== 'admin') {
|
||||
if (resourceSet === undefined && user.permission !== 'admin') {
|
||||
throw unauthorized()
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user