Improved On function to reflect data for callbacks and unmarshal it accordingly. (Panic problem though)