mitigate bug for campaigns that didn't get a success date
parent
499b079049
commit
242cb66451
|
@ -516,7 +516,10 @@ class Campaign(models.Model):
|
||||||
@property
|
@property
|
||||||
def success_date(self):
|
def success_date(self):
|
||||||
if self.status == 'SUCCESSFUL':
|
if self.status == 'SUCCESSFUL':
|
||||||
return self.actions.filter(type='succeeded')[0].timestamp
|
try:
|
||||||
|
return self.actions.filter(type='succeeded')[0].timestamp
|
||||||
|
except:
|
||||||
|
return ''
|
||||||
return ''
|
return ''
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue