DaanHoogland commented on code in PR #12779:
URL: https://github.com/apache/cloudstack/pull/12779#discussion_r2924533391
##########
server/src/main/java/com/cloud/vm/UserVmManagerImpl.java:
##########
@@ -5560,9 +5486,9 @@ public boolean finalizeStart(VirtualMachineProfile
profile, long hostId, Command
}
Answer answer = cmds.getAnswer("restoreVMSnapshot");
- if (answer != null && answer instanceof RestoreVMSnapshotAnswer) {
+ if (answer instanceof RestoreVMSnapshotAnswer) {
RestoreVMSnapshotAnswer restoreVMSnapshotAnswer =
(RestoreVMSnapshotAnswer) answer;
Review Comment:
but instanceof is supposed to handle that
##########
server/src/main/java/com/cloud/vm/UserVmManagerImpl.java:
##########
@@ -5560,9 +5486,9 @@ public boolean finalizeStart(VirtualMachineProfile
profile, long hostId, Command
}
Answer answer = cmds.getAnswer("restoreVMSnapshot");
- if (answer != null && answer instanceof RestoreVMSnapshotAnswer) {
+ if (answer instanceof RestoreVMSnapshotAnswer) {
RestoreVMSnapshotAnswer restoreVMSnapshotAnswer =
(RestoreVMSnapshotAnswer) answer;
Review Comment:
but `instanceof` is supposed to handle that
--
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]