Change to new callback format

This updates the code to use the new callback format