Modified check for continue running