Fixing bug in which variation gets chosen