Fixed ridiculous bug where the values for the right index were being skipped over b/c it was in an 'else if' instead of an 'if'