Revision bce67d66
b/snf-astakos-app/astakos/im/migrations/0023_populate_resource_data.py | ||
---|---|---|
19 | 19 |
sn, dict = args |
20 | 20 |
url = dict.get('url') |
21 | 21 |
policy = dict.get('quota') or () |
22 |
s, created = orm.Service.objects.get_or_create(name=sn, url=url) |
|
22 |
s, created = orm.Service.objects.get_or_create(name=sn, |
|
23 |
defaults={'url': url}) |
|
23 | 24 |
if not created and not s.url: |
24 | 25 |
s.url = url |
25 | 26 |
s.save() |
Also available in: Unified diff