Finally figure out what the data field is supposed to be for and use it to implement and fix 3LO.

This commit is contained in:
jakedt 2014-03-25 12:42:40 -04:00
parent e92cf37583
commit cbc40588cb
4 changed files with 33 additions and 7 deletions

View file

@ -287,7 +287,7 @@ class OAuthAuthorizationCode(BaseModel):
application = ForeignKeyField(OAuthApplication)
code = CharField(index=True)
scope = CharField()
data = CharField(default=random_string_generator())
data = CharField() # Context for the code, such as the user
class OAuthAccessToken(BaseModel):
@ -298,7 +298,7 @@ class OAuthAccessToken(BaseModel):
token_type = CharField(default='Bearer')
expires_at = DateTimeField()
refresh_token = CharField(index=True, null=True)
data = CharField() # What the hell is this field for?
data = TextField() # This is context for which this token was generated, such as the user
class NotificationKind(BaseModel):