Skip to content

Commit 698a705

Browse files
committed
order
Signed-off-by: Abhishek Kumar <[email protected]>
1 parent 01fd003 commit 698a705

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/KVMStorageProcessor.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2474,12 +2474,12 @@ public Answer handleDownloadTemplateToPrimaryStorage(DirectDownloadCommand cmd)
24742474
if (template != null) {
24752475
templatePath = template.getPath();
24762476
}
2477-
if (StringUtils.isEmpty(templatePath)) {
2478-
logger.warn("Skipped validation whether downloaded file is QCOW2 for template {}, due to downloaded template path is empty", template.getName());
2477+
if (ImageFormat.ISO.equals(cmd.getFormat())) {
2478+
logger.debug("Skipping template validations as image format is {}", cmd.getFormat());
2479+
} else if (StringUtils.isEmpty(templatePath)) {
2480+
logger.warn("Skipped validation whether downloaded file image {}, due to downloaded template path is empty", template.getName());
24792481
} else if (!new File(templatePath).exists()) {
24802482
logger.warn("Skipped validation whether downloaded file is QCOW2 for template {}, due to downloaded template path is not valid: {}", template.getName(), templatePath);
2481-
} else if (ImageFormat.ISO.equals(cmd.getFormat())) {
2482-
logger.debug("Skipping template validations as image format is {}", cmd.getFormat());
24832483
} else {
24842484
try {
24852485
Qcow2Inspector.validateQcow2File(templatePath);

0 commit comments

Comments
 (0)