From 3ffe6af6a52cdde13b53ee8cd0e3a42b7dfac628 Mon Sep 17 00:00:00 2001 From: Massimo Di Pierro Date: Sat, 17 Dec 2011 11:15:45 -0600 Subject: [PATCH] Pickable -> Pickeable, thanks Anthony --- VERSION | 2 +- gluon/storage.py | 2 +- gluon/tools.py | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/VERSION b/VERSION index dc67e1ef..0a6e54ff 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 1.99.4 (2011-12-17 10:10:41) stable +Version 1.99.4 (2011-12-17 11:15:12) stable diff --git a/gluon/storage.py b/gluon/storage.py index 4f09d69e..f31150d9 100644 --- a/gluon/storage.py +++ b/gluon/storage.py @@ -157,7 +157,7 @@ class Storage(dict): return None PICKABLE = (str,int,long,float,bool,list,dict,tuple,set) -def PickableStorage(data): +def PickeableStorage(data): return Storage(dict((k,v) for (k,v) in data.items() if isinstance(v,PICKABLE))) class StorageList(Storage): diff --git a/gluon/tools.py b/gluon/tools.py index 2981ec6e..bddf49a8 100644 --- a/gluon/tools.py +++ b/gluon/tools.py @@ -24,7 +24,7 @@ import cStringIO from email import MIMEBase, MIMEMultipart, MIMEText, Encoders, Header, message_from_string from contenttype import contenttype -from storage import Storage, PickableStorage, StorageList, Settings, Messages +from storage import Storage, PickeableStorage, StorageList, Settings, Messages from utils import web2py_uuid from fileutils import read_file from gluon import * @@ -1494,7 +1494,7 @@ class Auth(object): if user: password = table_user[passfield].validate(password)[0] if not user.registration_key and user[passfield] == password: - user = PickableStorage(user) + user = PickeableStorage(user) session.auth = Storage(user=user, last_visit=request.now, expiration=self.settings.expiration, hmac_key = web2py_uuid()) @@ -1771,7 +1771,7 @@ class Auth(object): # process authenticated users if user: - user = PickableStorage(user) + user = PickeableStorage(user) # process authenticated users # user wants to be logged in for longer