Setup event
Fixed a crash when exiting core in setup phase