explanatory error message on delete attempt of default system offering (#8883)

Co-authored-by: Gabriel Pordeus Santos <gabrielpordeus@gmail.com>
This commit is contained in:
dahn 2024-04-25 16:45:42 +02:00 committed by GitHub
parent cec6ade257
commit eead2710f8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -4204,7 +4204,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati
}
if (offering.getDefaultUse()) {
throw new InvalidParameterValueException("Default service offerings cannot be deleted");
throw new InvalidParameterValueException(String.format("The system service offering [%s] is marked for default use and cannot be deleted", offering.getDisplayText()));
}
final User user = _userDao.findById(userId);