core: Fix NPE when VM does not exists on register

Adding a null check if the VM sent in the parameters exists or not, to
prevent NPE.

Change-Id: I4fb846cc16d1d208f0b96a127169f717a3fec89e
Bug-Url: https://bugzilla.redhat.com/1148405
Signed-off-by: Maor Lipchuk <mlipchuk@redhat.com>
core: Formatting getExclusiveLocks at ImportVmCommand

Formatting getExclusiveLocks at ImportVmCommand

Change-Id: If0c2797b3e843015fb5eae6829a098fd203652ce
Signed-off-by: Maor Lipchuk <mlipchuk@redhat.com>