Show More
@@ -145,11 +145,12 b' class UsersController(BaseController):' | |||||
145 | user_model = UserModel() |
|
145 | user_model = UserModel() | |
146 | try: |
|
146 | try: | |
147 | user_model.delete(id) |
|
147 | user_model.delete(id) | |
|
148 | Session.commit() | |||
148 | h.flash(_('successfully deleted user'), category='success') |
|
149 | h.flash(_('successfully deleted user'), category='success') | |
149 | Session.commit() |
|
|||
150 | except (UserOwnsReposException, DefaultUserException), e: |
|
150 | except (UserOwnsReposException, DefaultUserException), e: | |
151 |
h.flash( |
|
151 | h.flash(e, category='warning') | |
152 | except Exception: |
|
152 | except Exception: | |
|
153 | log.error(traceback.format_exc()) | |||
153 | h.flash(_('An error occurred during deletion of user'), |
|
154 | h.flash(_('An error occurred during deletion of user'), | |
154 | category='error') |
|
155 | category='error') | |
155 | return redirect(url('users')) |
|
156 | return redirect(url('users')) |
General Comments 0
You need to be logged in to leave comments.
Login now