Skip to content

Commit af5db76

Browse files
committed
CA-272679: Fix error args of feature check for VM.pool_migrate
The error takes the feature name as argument. Signed-off-by: Rob Hoes <[email protected]>
1 parent 221b9ce commit af5db76

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

ocaml/xapi/xapi_vm_migrate.ml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -234,8 +234,7 @@ let infer_vgpu_map ~__context ?remote vm =
234234
) vgpus
235235

236236
let pool_migrate ~__context ~vm ~host ~options =
237-
if (not (Pool_features.is_enabled ~__context Features.Xen_motion)) then
238-
raise (Api_errors.Server_error(Api_errors.license_restriction, []));
237+
Pool_features.assert_enabled ~__context ~f:Features.Xen_motion;
239238
let dbg = Context.string_of_task __context in
240239
let open Xapi_xenops_queue in
241240
let queue_name = queue_of_vm ~__context ~self:vm in

0 commit comments

Comments
 (0)