Skip to content

Commit adb0363

Browse files
committed
Merge branch 'master' into rel
2 parents b944cb7 + 60fb1a3 commit adb0363

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# -*- coding: utf-8 -*-
2+
# Generated by Django 1.11.27 on 2020-02-18 19:00
3+
from __future__ import unicode_literals
4+
5+
from django.db import migrations
6+
7+
8+
def forwards_func(apps, schema_editor):
9+
"""Old models with provider_data='' are being fetched as str instead of json."""
10+
Integration = apps.get_model('integrations', 'Integration')
11+
12+
Integration.objects.filter(
13+
provider_data='',
14+
).update(
15+
provider_data={},
16+
)
17+
18+
19+
class Migration(migrations.Migration):
20+
21+
dependencies = [
22+
('integrations', '0006_set-default-value-provider-data'),
23+
]
24+
25+
operations = [
26+
migrations.RunPython(forwards_func),
27+
]

0 commit comments

Comments
 (0)