fix the defect token would not pass to listener
state save/restore