Fixes logic of if statements in index for projects and memberships.