Fixed a couple of bugs that made no real sense till I realized I made a couple of dumb mistakes.