refactor into a single Callback interface
update to use callback