Github user rafaelweingartner commented on a diff in the pull request: https://github.com/apache/cloudstack/pull/1365#discussion_r60095758 --- Diff: server/src/com/cloud/storage/VolumeApiServiceImpl.java --- @@ -1835,6 +1847,26 @@ private Volume orchestrateDetachVolumeFromVM(long vmId, long volumeId) { } } + public void updateMissingRootDiskController(final VMInstanceVO vm, final String rootVolChainInfo) { + if (vm == null || !vm.getType().equals(VirtualMachine.Type.User) || Strings.isNullOrEmpty(rootVolChainInfo)) { --- End diff -- @bhaisaab I was no talking about removing the "vm != null", that check I know we need to execute. I was only refering to the "vm.getType().equals(VirtualMachine.Type.User)", the "vm.getType" can return a null value. Did you understand what I mean? Just inverting the comparison as I said before. from `vm.getType().equals(VirtualMachine.Type.User)` to `VirtualMachine.Type.User.equals(vm.getType())`
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---