fixed critical bug!