added basic callback functionality