fix a critical bug