def main(argv=None): if sys.argv: argv = sys.argv queries = kodi.parse_query(sys.argv[2]) logger.log('Version: |%s| Queries: |%s|' % (kodi.get_version(), queries)) logger.log('Args: |%s|' % (argv)) # don't process params that don't match our url exactly. (e.g. plugin://plugin.video.1channel/extrafanart) plugin_url = 'plugin://%s/' % (kodi.get_id()) if argv[0] != plugin_url: return mode = queries.get('mode', None) url_dispatcher.dispatch(mode, queries)
def main(argv=None): if sys.argv: argv = sys.argv queries = kodi.parse_query(sys.argv[2]) logger.log('Version: |%s| Queries: |%s|' % (kodi.get_version(), queries)) logger.log('Args: |%s|' % (argv)) # don't process params that don't match our url exactly. (e.g. plugin://plugin.video.1channel/extrafanart) plugin_url = 'plugin://%s/' % (kodi.get_id()) if argv[0] != plugin_url: return mode = queries.get('mode', None) url_dispatcher.dispatch(mode, queries)