Updated the functions in the file