From: Ben Darnell Date: Sat, 1 May 2010 00:28:40 +0000 (-0700) Subject: Allow for missing "expires" field in facebook session, which can X-Git-Tag: v1.0.0~45 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=00ad92f3982b7cb6f4634186b98219816cc5dac0;p=thirdparty%2Ftornado.git Allow for missing "expires" field in facebook session, which can happen if offline_access is granted. --- diff --git a/tornado/auth.py b/tornado/auth.py index e17c89a23..57db36e91 100644 --- a/tornado/auth.py +++ b/tornado/auth.py @@ -813,7 +813,7 @@ class FacebookMixin(object): "profile_url": users[0]["profile_url"], "username": users[0].get("username"), "session_key": session["session_key"], - "session_expires": session["expires"], + "session_expires": session.get("expires"), }) def _parse_response(self, callback, response):