adds callback, takes out unecessary modules, adds better commenting.