fixed logic error in startup state