Image.checkEdit (usr, level)
check if user is allowed to edit an image

  • Parameter Obj:
    Userobject
  • Parameter Int:
    Permission-Level
  • Returns
    Obj Exception or null (if allowed)
Sourcecode in Image/securityFunctions.js:
1:   function checkEdit(usr, level) {
2:      if (this.creator != usr && (level & MAY_EDIT_ANYIMAGE) == 0)
3:         throw new DenyException("imageEdit");
4:      return;
5:   }