diff --git a/xCAT-server/lib/xcat/plugins/esx.pm b/xCAT-server/lib/xcat/plugins/esx.pm index 3bd86d81e..151ed77a3 100644 --- a/xCAT-server/lib/xcat/plugins/esx.pm +++ b/xCAT-server/lib/xcat/plugins/esx.pm @@ -865,15 +865,15 @@ sub get_hostview { push @matchvalues,$_; } my $view; - $subargs{filter}={'name' =~ qr/$host(?:\.|\z)/}; + $subargs{filter}={'name' => qr/$host(?:\.|\z)/}; $view = $args{conn}->find_entity_view(%subargs); if ($view) { return $view; } foreach (@matchvalues) { - $subargs{filter}={'name' =~ qr/$_(?:\.|\z)/}; + $subargs{filter}={'name' => qr/$_(?:\.|\z)/}; $view = $args{conn}->find_entity_view(%subargs); if ($view) { return $view; } } - $subargs{filter}={'name' =~ qr/localhost(?:\.|\z)/}; + $subargs{filter}={'name' => qr/localhost(?:\.|\z)/}; $view = $args{conn}->find_entity_view(%subargs); if ($view) { return $view; } return undef; #rest of function should be obsoleted, going to run with that assumption for 2.5 at least