bugfix -- OOPS, this bug took me two days work to notice :(