Filter the for(var k in ...) entries with hasOwnProperty() call in RoleEditor. Fixes #789