optimizing voter method to perform 1 query instead of 2