diff options
author | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2014-08-25 16:26:58 +0700 |
---|---|---|
committer | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2014-08-25 16:26:58 +0700 |
commit | 7fa1eb17f907fe5c3878a331960cdd59217db43c (patch) | |
tree | dbbb030efcc3e3e8a42f98149bc8a3f577070797 /askbot/models/__init__.py | |
parent | c11627a6386f0b3568dea83f98f423194efb835c (diff) | |
download | askbot-7fa1eb17f907fe5c3878a331960cdd59217db43c.tar.gz askbot-7fa1eb17f907fe5c3878a331960cdd59217db43c.tar.bz2 askbot-7fa1eb17f907fe5c3878a331960cdd59217db43c.zip |
fixed correctness issue in the CivicDuty badge awards and allowed to edit comments by high reputation users
Diffstat (limited to 'askbot/models/__init__.py')
-rw-r--r-- | askbot/models/__init__.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/askbot/models/__init__.py b/askbot/models/__init__.py index dd992c99..6919ebeb 100644 --- a/askbot/models/__init__.py +++ b/askbot/models/__init__.py @@ -863,6 +863,10 @@ def user_assert_can_edit_comment(self, comment = None): else: return + if not (self.is_blocked() or self.is_suspended()): + if self.reputation >= askbot_settings.MIN_REP_TO_EDIT_OTHERS_POSTS: + return + error_message = _( 'Sorry, but only post owners or moderators can edit comments' ) |