Filter info pages and search results for guests

This commit is contained in:
JonnyWong16 2016-04-26 22:07:36 -07:00
parent 4d057a1c5e
commit 0f851ec2a3
3 changed files with 15 additions and 5 deletions

View file

@ -1859,6 +1859,9 @@ class WebInterface(object):
metadata['poster_url'] = poster_url
if metadata:
if metadata['section_id'] and not allow_session_library(metadata['section_id']):
raise cherrypy.HTTPRedirect(plexpy.HTTP_ROOT)
return serve_template(templatename="info.html", data=metadata, title="Info", config=config, source=source)
else:
return self.update_metadata(rating_key, query)
@ -1901,7 +1904,7 @@ class WebInterface(object):
cherrypy.response.headers['Content-type'] = 'image/png'
return fallback_image
except IOError, e:
logger.error(u"Unable to read fallback %s image: %s" % (fallback, e))
logger.error(u"Unable to read fallback %s image: %s" % (fallback, e))
return None