fixed a dumb dumb logic error