More logic error fixes.