Added onSwitchFinish event