def sickbeard(): try: sickbeard = sickbeard_api('/?cmd=future&sort=date') if sickbeard['result'].rfind('success') >= 0: sickbeard = sickbeard['data'] for time in sickbeard: for episode in sickbeard[time]: episode['image'] = get_pic(episode['tvdbid'], 'banner') except Exception as e: logger.log('Could not retrieve sickbeard - %s]' % (e), 'WARNING') sickbeard = None return render_template('mobile/sickbeard/coming_episodes.html', coming_episodes=sickbeard, )
def sickbeard_all(): try: sickbeard = sickbeard_api('/?cmd=shows&sort=name') if sickbeard['result'].rfind('success') >= 0: sickbeard = sickbeard['data'] for show in sickbeard: sickbeard[show]['url'] = get_pic(sickbeard[show]['tvdbid'], 'banner') except Exception as e: logger.log('Could not retrieve sickbeard - %s]' % (e), 'WARNING') sickbeard = None return render_template('mobile/sickbeard/all.html', shows=sickbeard, )
def sickbeard_all(): try: sickbeard = sickbeard_api('/?cmd=shows&sort=name') if sickbeard['result'].rfind('success') >= 0: sickbeard = sickbeard['data'] for show in sickbeard: sickbeard[show]['url'] = get_pic(sickbeard[show]['tvdbid'], 'banner') except Exception as e: logger.log('Could not retrieve sickbeard - %s]' % (e), 'WARNING') sickbeard = None return render_template( 'mobile/sickbeard/all.html', shows=sickbeard, )