Skip to content

Commit ef29e99

Browse files
committed
remove else block and fix the error string
1 parent 2add1ba commit ef29e99

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

server/src/main/java/com/cloud/api/query/dao/TemplateJoinDaoImpl.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -174,12 +174,10 @@ private String getTemplateStatus(TemplateJoinVO template) {
174174
} else if (template.getDownloadState() == Status.BYPASSED) {
175175
templateStatus = "Bypassed Secondary Storage";
176176
} else if (StringUtils.isNotBlank(template.getErrorString())) {
177-
templateStatus = template.getTemplateState().toString();
177+
templateStatus = template.getErrorString().trim();
178178
}
179179
} else if (template.getDownloadState() == Status.DOWNLOADED) {
180180
templateStatus = "Download Complete";
181-
} else {
182-
templateStatus = "Successfully Installed";
183181
}
184182
return templateStatus;
185183
}

0 commit comments

Comments
 (0)