Moved callback storage to fix spurious error callbacks when going offline