One more fix to shutdown