fnp
/
wolnelektury.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
fix
[wolnelektury.git]
/
src
/
club
/
migrations
/
0043_monthlyamount_wide_singleamount_wide.py
diff --git
a/src/club/migrations/0043_monthlyamount_wide_singleamount_wide.py
b/src/club/migrations/0043_monthlyamount_wide_singleamount_wide.py
index
0c696b2
..
c73450c
100644
(file)
--- a/
src/club/migrations/0043_monthlyamount_wide_singleamount_wide.py
+++ b/
src/club/migrations/0043_monthlyamount_wide_singleamount_wide.py
@@
-6,8
+6,9
@@
from django.db import migrations, models
def last_amount_wide(apps, schema_editor):
SingleAmount = apps.get_model('club', 'SingleAmount')
a = SingleAmount.objects.last()
- a.wide = True
- a.save()
+ if a is not None:
+ a.wide = True
+ a.save()
class Migration(migrations.Migration):