bug fixed from scott