Ejemplo n.º 1
0
    def pre(self):
        if request.host != g.media_domain:
            # don't serve up untrusted content except on our
            # specifically untrusted domain
            self.abort404()

        MinimalController.pre(self)

        c.allow_framing = True
Ejemplo n.º 2
0
    def pre(self):
        if request.host != g.media_domain:
            # don't serve up untrusted content except on our
            # specifically untrusted domain
            self.abort404()

        MinimalController.pre(self)

        c.allow_framing = True
Ejemplo n.º 3
0
    def __before__(self, event):
        MinimalController.__before__(self)

        if event:
            try:
                c.liveupdate_event = LiveUpdateEvent._byID(event)
            except tdb_cassandra.NotFound:
                pass

        if not c.liveupdate_event:
            self.abort404()
    def __before__(self, event):
        MinimalController.__before__(self)

        if event:
            try:
                c.liveupdate_event = LiveUpdateEvent._byID(event)
            except tdb_cassandra.NotFound:
                pass

        if not c.liveupdate_event:
            self.abort404()
Ejemplo n.º 5
0
 def pre(self):
     MinimalController.pre(self)
     c.user = g.auth_provider.get_authenticated_account()
     if c.user and c.user._deleted:
         c.user = None
     c.user_is_loggedin = bool(c.user)
Ejemplo n.º 6
0
 def pre(self):
     MinimalController.pre(self)
     c.user = g.auth_provider.get_authenticated_account()
     if c.user and c.user._deleted:
         c.user = None
     c.user_is_loggedin = bool(c.user)