It gives an array with objects. So in_array()
won’t find anything, you have to convert it before. After you get the results from wbdb:
$employees_array = array();
foreach($employees as $employee) {
$employees_array[] = $employee->meta_value;
}
if(in_array($company, $employees_array)) {
...
}