fixed stopping bug