improved the functions.php