projects
/
mediagoblin.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5c2b848
)
Remove SimpleFieldAlias
author
Sebastian Spaeth
<Sebastian@SSpaeth.de>
Thu, 20 Dec 2012 22:10:07 +0000
(23:10 +0100)
committer
Sebastian Spaeth
<Sebastian@SSpaeth.de>
Thu, 20 Dec 2012 23:30:48 +0000
(
00:30
+0100)
It was only used for the model._id -> model.id conversion and is not
needed anymore.
Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
mediagoblin/db/sql/models.py
patch
|
blob
|
blame
|
history
diff --git
a/mediagoblin/db/sql/models.py
b/mediagoblin/db/sql/models.py
index 8315d05c0f9e905d7c2df249bdbfc9cd3ed82b6b..4450e38d984a1aba4c5322369ae8bf41206b77a6 100644
(file)
--- a/
mediagoblin/db/sql/models.py
+++ b/
mediagoblin/db/sql/models.py
@@
-44,18
+44,6
@@
from mediagoblin.db.sql.base import Session
from migrate import changeset
-class SimpleFieldAlias(object):
- """An alias for any field"""
- def __init__(self, fieldname):
- self.fieldname = fieldname
-
- def __get__(self, instance, cls):
- return getattr(instance, self.fieldname)
-
- def __set__(self, instance, val):
- setattr(instance, self.fieldname, val)
-
-
class User(Base, UserMixin):
"""
TODO: We should consider moving some rarely used fields