Skip to content

Commit a90422a

Browse files
shwstpprdhslove
authored andcommitted
server: remove extra chars when template status is error string (apache#11329)
Fixes apache#11324 Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
1 parent 8b47074 commit a90422a

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

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

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -172,10 +172,10 @@ private String getTemplateStatus(TemplateJoinVO template) {
172172
}
173173
} else if (template.getDownloadState() == Status.BYPASSED) {
174174
templateStatus = "Bypassed Secondary Storage";
175-
}else if (template.getErrorString()==null){
175+
} else if (template.getErrorString() == null) {
176176
templateStatus = template.getTemplateState().toString();
177-
}else {
178-
templateStatus = template.getErrorString();
177+
} else {
178+
templateStatus = template.getErrorString().trim();
179179
}
180180
} else if (template.getDownloadState() == Status.DOWNLOADED) {
181181
templateStatus = "Download Complete";

0 commit comments

Comments
 (0)