summaryrefslogtreecommitdiff
path: root/pgcommitfest/commitfest/views.py
diff options
context:
space:
mode:
authorMagnus Hagander2015-02-06 11:13:22 +0000
committerMagnus Hagander2015-02-06 11:13:22 +0000
commit0219f08444d8840a65cdb08a18a897f2777cd0f5 (patch)
treef15dbc78953b3aaaee02c1ebdd229540529caf04 /pgcommitfest/commitfest/views.py
parent5ec1b2a727eba4e3f4a70028a975d12dffc03ccb (diff)
Stop using "added self" in history entries
Instead include the actual username. Makes it easier to work with in the history views, and is also probably more proper english.
Diffstat (limited to 'pgcommitfest/commitfest/views.py')
-rw-r--r--pgcommitfest/commitfest/views.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/pgcommitfest/commitfest/views.py b/pgcommitfest/commitfest/views.py
index 3e0dcd1..3268b7e 100644
--- a/pgcommitfest/commitfest/views.py
+++ b/pgcommitfest/commitfest/views.py
@@ -472,11 +472,11 @@ def reviewer(request, cfid, patchid, status):
if status=='become' and not is_reviewer:
patch.reviewers.add(request.user)
patch.set_modified()
- PatchHistory(patch=patch, by=request.user, what='Added self as reviewer').save()
+ PatchHistory(patch=patch, by=request.user, what='Added %s as reviewer' % request.user.username).save()
elif status=='remove' and is_reviewer:
patch.reviewers.remove(request.user)
patch.set_modified()
- PatchHistory(patch=patch, by=request.user, what='Removed self from reviewers').save()
+ PatchHistory(patch=patch, by=request.user, what='Removed %s from reviewers' % request.user.username).save()
return HttpResponseRedirect('../../')
@login_required
@@ -495,11 +495,11 @@ def committer(request, cfid, patchid, status):
if status=='become' and not is_committer:
patch.committer = committer
patch.set_modified()
- PatchHistory(patch=patch, by=request.user, what='Added self as committer').save()
+ PatchHistory(patch=patch, by=request.user, what='Added %s as committer' % request.user.username).save()
elif status=='remove' and is_committer:
patch.committer = None
patch.set_modified()
- PatchHistory(patch=patch, by=request.user, what='Removed self from committers').save()
+ PatchHistory(patch=patch, by=request.user, what='Removed %s from committers' % request.user.username).save()
patch.save()
return HttpResponseRedirect('../../')