bugfix in normalize