fixed a bug with voting