Create and add function to hand-logic.php