updating the functionality