Support Want-OPDS-Catalog HTTP header in content server

This commit is contained in:
Kovid Goyal 2009-07-07 10:05:22 -06:00
parent 50f6de082a
commit 151ffab821

View File

@ -366,10 +366,9 @@ class LibraryServer(object):
@expose @expose
def index(self, **kwargs): def index(self, **kwargs):
'The / URL' 'The / URL'
stanza = cherrypy.request.headers.get('Stanza-Device-Name', 919) want_opds = cherrypy.request.headers.get('Stanza-Device-Name', 919) != \
if stanza == 919: 919 or cherrypy.request.headers.get('Want-OPDS-Catalog', 919) != 919
return self.static('index.html') return self.stanza() if want_opds else self.static('index.html')
return self.stanza()
@expose @expose