weizhouapache commented on code in PR #9113:
URL: https://github.com/apache/cloudstack/pull/9113#discussion_r1614426888
##########
server/src/main/java/com/cloud/vm/UserVmManagerImpl.java:
##########
@@ -7844,9 +7844,10 @@ public UserVm restoreVirtualMachine(final Account
caller, final long vmId, final
}
vm.setPassword(password);
}
+ UserVmDetailVO userVmPasswordDetail =
userVmDetailsDao.findDetail(vm.getId(), VmDetailConstants.PASSWORD);
if (needRestart) {
try {
- if (vm.getDetail(VmDetailConstants.PASSWORD) != null) {
+ if (Objects.nonNull(userVmPasswordDetail)) {
Review Comment:
@Pearl1594
does this work ?
```
if (password != null) {
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]