Fixed two small errors.
Removed an unnecessary edit_extra field in club.py.
And made group.py call getForCurrentAccount where necessary.
Patch by: Lennard de Rijk
Reviewed by: to-be-reviewed
--- a/app/soc/views/models/club.py Sat Jan 31 18:55:34 2009 +0000
+++ b/app/soc/views/models/club.py Sat Jan 31 18:58:09 2009 +0000
@@ -94,8 +94,6 @@
club_logic, club_app_logic)
}
new_params['edit_extra_dynafields'] = {
- 'founded_by': forms.CharField(widget=widgets.ReadOnlyInput(),
- required=False),
'clean_link_id': cleaning.clean_link_id('link_id')
}
--- a/app/soc/views/models/group.py Sat Jan 31 18:55:34 2009 +0000
+++ b/app/soc/views/models/group.py Sat Jan 31 18:58:09 2009 +0000
@@ -102,8 +102,7 @@
if not entity:
# only if we are creating a new entity we should fill in founder
- account = users.get_current_user()
- user = user_logic.logic.getForFields({'account': account}, unique=True)
+ user = user_logic.logic.getForCurrentAccount()
fields['founder'] = user
super(View, self)._editPost(request, entity, fields)