defined callback functions for the save keys functions