I would like to prevent self-vote from the node author. I skimmed all the code but have no idea how to work around this issue.

Comments

Chill35’s picture

A node author can vote once on his content.

Believe it or not, I had at some point someone sponsor the development of this module with a small amount of money, and he wanted authors to be able to vote once on their content. This wasn't possible before, and I made that possible.

You simply have to do a check before you store the vote in the code. If you propose a patch that makes this optional, I am willing to commit it.

manop’s picture

Thank you for the answer. I don't know much about the coding. So I hid the arrow key instead by changing the line

    else if (user_access('vote on content')) {

to

    else if (user_access('vote on content') && !$is_author) {

It works okay for me now.

NancyDru’s picture

Status: Active » Fixed

Committed to 6.x-2.x-dev. There is now an option for this.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.