Add is_mobile function in functions.php.