Added exiting callback to finding page function.