Added callback support

Minor changes