class OsmBackend(object):
+
def authenticate(self, **kwargs):
'''
kwargs will receive the python dict that may contain
user.psw = password
user.token = result['data']['id']
user.project_id = result['data']['project_id']
+ user.project_name = result['data']['project_name']
user.token_expires = result['data']['expires']
user.is_admin = bool(result['data']['admin'])
user.save()
return OsmUser.objects.get(pk=user_id)
except OsmUser.DoesNotExist:
return None
+