MasterAccessControlEntryEntity entity = findByUserIdDomainInterfaceNameOperationAndType(updatedMasterAce.getUid(),
updatedMasterAce.getDomain(),
updatedMasterAce.getInterfaceName(),
updatedMasterAce.getOperation(),
type);
<BUG>if (entity == null) {
entity = new MasterAccessControlEntryEntity();</BUG>
entity.setUserId(updatedMasterAce.getUid());
entity.setDomain(updatedMasterAce.getDomain());
entity.setInterfaceName(updatedMasterAce.getInterfaceName());

MasterAccessControlEntryEntity entity = findByUserIdDomainInterfaceNameOperationAndType(updatedMasterAce.getUid(),
updatedMasterAce.getDomain(),
updatedMasterAce.getInterfaceName(),
updatedMasterAce.getOperation(),
type);
boolean created = entity == null;
if (created) {
entity = new MasterAccessControlEntryEntity();
entity.setUserId(updatedMasterAce.getUid());
entity.setDomain(updatedMasterAce.getDomain());
entity.setInterfaceName(updatedMasterAce.getInterfaceName());
