tidy up
remove the need to test callbacks as functions
tidy up