def backwards_move_org_source(apps, schema_editor):
 RemoteOrganization = apps.get_model(u'oauth', u'RemoteOrganization')
 SocialAccount = apps.get_model(u'socialaccount', u'SocialAccount')
 for account in SocialAccount.objects.all():
  rows = account.remote_organizations.update(account=None, source=account.provider)

def backwards_move_org_source ( apps , schema_editor ) : RemoteOrganization = apps . get_model ( u'oauth' , u'RemoteOrganization' ) SocialAccount = apps . get_model ( u'socialaccount' , u'SocialAccount' ) for account in SocialAccount . objects . all ( ) : rows = account . remote_organizations . update ( account = None , source = account . provider )
use source field to set organization account .