Added callback to state update