1
0
mirror of https://github.com/ae-utbm/sith.git synced 2025-03-31 08:50:26 +00:00

Merge branch 'com' into 'master'

com: fix error 500 when editing poster with com admin

See merge request 
This commit is contained in:
Antoine Bartuccio 2019-10-06 17:55:30 +02:00
commit 448f5ff40f

@ -739,8 +739,7 @@ class PosterEditBaseView(UpdateView):
def get_context_data(self, **kwargs):
kwargs = super(PosterEditBaseView, self).get_context_data(**kwargs)
if not self.request.user.is_com_admin:
kwargs["club"] = self.club
kwargs["club"] = kwargs.get("club", self.club)
return kwargs
def form_valid(self, form):