What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 134 Stack Exchange communities.

A useful edit was rejected. I had previously edited the code in an answer of mine, but failed to replace a reference to a temp variable I had removed. An astute reader noticed the problem and proposed an edit -- only to have it rejected.

Basically, I would like to give the guy credit for his work, and save him from any adverse consequences of the rejected edit. What can I do? Not much, I suppose, other than review his recent activity and +1 where it makes sense, to compensate. But I'm thinking there should be a way to contest rejected edits somehow. Or can I flag the edit reason for moderator attention somehow?

Also related, tangentially related.

share|improve this question
5  
It's +2 rep. That's hardly a loss, really. One upvote on a good answer of the other user pays for that 5 times over! –  Martijn Pieters Sep 12 '12 at 11:27
5  
Just edit it in yourself. Suggested code edits are often not accepted. Correct it and no harm done. –  Bart Sep 12 '12 at 11:30
    
Heeded both suggestions. Thanks for the quick replies. Anybody care to explain why they downvoted my question? –  tripleee Sep 12 '12 at 11:31
    
Pff, who knows. Perhaps because you could have easily figured out the answer to the question in your title? I don't know. –  Bart Sep 12 '12 at 11:34
    
See the faq; votes on MSO are different from the regular Stack Exchange websites. I guess people felt that contesting the rejected edit was not needed and they expressed that with a downvote. –  Martijn Pieters Sep 12 '12 at 11:35
    
If you post a suggested edit, please try to fix multiple issues. –  Toon Krijthe Sep 12 '12 at 11:37
7  
You should never make edits to code blocks. Rather leave a comment to the OP and let him make the changes. This is the case with questions and answers a-like. Editing code blocks can change the operation/meaning of the post quite drastically. –  Lix Sep 12 '12 at 11:38
1  
@Lix: Thanks, that could at least explain the reasoning for rejecting. –  tripleee Sep 12 '12 at 11:44
    
@ToonKrijthe : what if there's only ONE issue that needs to be addressed? –  C.B. May 30 '13 at 12:53
    
@Lix : "Editing code blocks can change the operation/meaning of the post quite drastically" - but the change can sometimes be an improvement, such as it was in this case: the original code was WRONG and the edit CORRECTED it. Why would you say "never"? –  C.B. May 30 '13 at 12:57

3 Answers 3

up vote 7 down vote accepted

You can't contest an edit, although you can start a discussion on meta.

But you can re-suggest it if you really think it is useful.

But keep in mind that an edit must be substantial without changing the meaning of the post.

share|improve this answer

Since I'm responsible for one of the reject votes, I probably should chip in.

In general, I reject suggested code edits especially when the original post was by a high-rep user. Too often do we see invalid/irrelevant edits to code, and it should not be incumbent upon reviewers to grok the entire post just to validate a code edit.

My rationale on why code edits should be discouraged:

  • minor errors and typos in code are better addressed with comments. The OP is the best person to judge if the edit is correct; he/she will get notified of the comment and has the option to make the edit, ignore, or respond to it.
  • major errors in the code should be downvoted instead
  • for code improvements, if the editor believes there's a better way to do it he/she should post a separate answer instead

Naturally, every now and then valid edits such as this will get caught in the net. For that I am sorry, but I'm willing to take some casualties for the sake of keeping those bandit edits out.

share|improve this answer
    
+1 Thanks for the substantial follow-up. –  tripleee Sep 12 '12 at 12:57
    
You're welcome :) –  Shawn Chin Sep 12 '12 at 12:59
4  
I always click "not sure" if code is edited in an answer and I don't understand what's happening... –  ben is uǝq backwards Sep 12 '12 at 12:59
    
I used to do that too, but realised I was just passing the decision on to someone else. The fact that it is a vote means that it is our priviledge/responsibility to indicate what kind of edits we would like to see made on the site -- I believe such edits are wrong, others have the rights to disagree. Overall, the majority will have its way. –  Shawn Chin Sep 12 '12 at 13:05
    
While we're on the topic, I'm keen to know how my vote stands up against others just so I may be swayed by majority decision hence this feature request. Too bad it never took off. –  Shawn Chin Sep 12 '12 at 13:07

Suggested edits should not change the code shown in an answer; they can change the formatting of the code, if that makes the code more readable, though.
If the code is using the wrong function, a suggested edit should not change the function call with the correct one; if the code is completely wrong, a suggested edit should not change it to a more correct one. In both the cases, who suggested the edit could write her/his own answer.

As the answers is one of yours, you can simply edit it to fix the code.

share|improve this answer
4  
If the code is using the wrong function -> Really? I always accept suggested edits if they fix a blatant problem with the code. The times where my answers have been updated to fix blatant problems e.g., I've been grateful. –  Matt Sep 12 '12 at 14:17
    
Would you accept an edit to an answer written from another user, and that changes ereg() with str_replace()? Wrong also mean "undesirable or unsuitable." –  kiamlaluno Sep 12 '12 at 14:31
    
Of course not. Would you accept an edit which changed stringreplace() to str_replace() (typical problem with PHP's lack of naming scheme). –  Matt Sep 12 '12 at 14:37
    
In that case, I would rather prefer a comment for the author to make her/him notice that. If the user replies with "You are wrong; PHP has string replace()." then you know the answer is wrong; if s/he replies with "Oh, you are right. It was a typo." you know s/he just typo-ed the function name. –  kiamlaluno Sep 12 '12 at 14:44
1  
Then that's where we disagree I guess :). I'd prefer to accept the edit. The owner gets a notification saying their code has been edited. If they strongly disagree with the blatant correction, then they can roll back; but in 99% of the cases, I don't expect that to happen. –  Matt Sep 12 '12 at 14:50

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .