add function for vote