@locks command bug fixed; Had forgotten a 'not' in the lock-check, reversing the result.

This commit is contained in:
Griatch 2011-03-16 07:16:32 +00:00
parent 08b3de9e5e
commit 295a82cc04

View file

@ -1299,7 +1299,7 @@ class CmdLock(ObjManipCommand):
if lockdef:
string = lockdef[2]
if 'del' in self.switches:
if obj.access(caller, 'edit'):
if not obj.access(caller, 'edit'):
caller.msg("You are not allowed to do that.")
return
obj.locks.delete(access_type)
@ -1315,7 +1315,7 @@ class CmdLock(ObjManipCommand):
obj = caller.search(objname)
if not obj:
return
if obj.access(caller, 'edit'):
if not obj.access(caller, 'edit'):
caller.msg("You are not allowed to do that.")
return
ok = obj.locks.add(lockdef, caller)