Got the functions to seperate in todo.js