Permalink
Browse files

wiki: Revert should have the author of the reverter.

  • Loading branch information...
1 parent 35bec69 commit 449b7a8410b082c982b5b4ffd0bef98b0cae6272 @andre-d andre-d committed with spladug Nov 12, 2012
Showing with 1 addition and 2 deletions.
  1. +1 −2 r2/r2/controllers/wiki.py
@@ -332,7 +332,6 @@ def POST_wiki_revision_revert(self, pv):
if not revision:
self.handle_error(400, 'INVALID_REVISION')
content = revision.content
- author = revision._get('author')
reason = 'reverted back %s' % timesince(revision.date)
if page.name == 'config/stylesheet':
report, parsed = c.site.parse_css(content)
@@ -341,7 +340,7 @@ def POST_wiki_revision_revert(self, pv):
c.site.change_css(content, parsed, prev=None, reason=reason, force=True)
else:
try:
- page.revise(content, author=author, reason=reason, force=True)
+ page.revise(content, author=c.user._id36, reason=reason, force=True)
# continue storing the special pages as data attributes on the subreddit
# object. TODO: change this to minimize subreddit get sizes.

0 comments on commit 449b7a8

Please sign in to comment.