consolidate shared vote code