public function isEmpty($data) { if (is_null($data) || count($data) == 0) { return true; } return false; }