private function checkLvl($lvl) { if (!is_int($lvl)) { return false; } if ($lvl > 9) { return false; } return true; }