GaOrtiga commented on code in PR #8556:
URL: https://github.com/apache/cloudstack/pull/8556#discussion_r1465051345


##########
server/src/main/java/com/cloud/template/HypervisorTemplateAdapter.java:
##########
@@ -748,9 +748,6 @@ void checkAndRemoveTemplateDetails(VMTemplateVO template) {
     public TemplateProfile prepareDelete(DeleteTemplateCmd cmd) {
         TemplateProfile profile = super.prepareDelete(cmd);
         VMTemplateVO template = profile.getTemplate();
-        if (template.getTemplateType() == TemplateType.SYSTEM) {
-            throw new InvalidParameterValueException("The DomR template cannot 
be deleted.");
-        }

Review Comment:
   > ```
   >         if (template.getTemplateType() == TemplateType.SYSTEM && ! 
cmd.isForced()) {
   >             throw new InvalidParameterValueException("The DomR template 
cannot be deleted.");
   >         }
   > ```
   > 
   > is what you mean @GaOrtiga ?
   
   @DaanHoogland @weizhouapache given that this operation can only be carried 
out by Root Admins, could we proceed with this proposed implementation?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to