adding the updated functions