cubicweb/pyramid/syncsession.py
changeset 12025 ba79f4a4f5d8
parent 12024 5f46195b9595
child 12026 c21b399c9269
--- a/cubicweb/pyramid/syncsession.py	Fri Mar 10 12:01:31 2017 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,29 +0,0 @@
-# copyright 2016 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
-# contact http://www.logilab.fr/ -- mailto:contact@logilab.fr
-#
-# This file is part of CubicWeb.
-#
-# CubicWeb is free software: you can redistribute it and/or modify it under the
-# terms of the GNU Lesser General Public License as published by the Free
-# Software Foundation, either version 2.1 of the License, or (at your option)
-# any later version.
-#
-# CubicWeb is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
-# details.
-#
-# You should have received a copy of the GNU Lesser General Public License along
-# with CubicWeb.  If not, see <http://www.gnu.org/licenses/>.
-"""Override cubicweb's syncsession hooks to handle them in the pyramid's way"""
-
-from logilab.common.decorators import monkeypatch
-from cubicweb.hooks import syncsession
-
-
-def includeme(config):
-
-    @monkeypatch(syncsession)
-    def get_user_sessions(cnx, user_eid):
-        if cnx.user.eid == user_eid:
-            yield cnx