with open(BuliFile, 'r') as Mannschaften: BuliMannschaften = Mannschaften.read().rstrip('\n').decode('utf-8') # Create Objects ph = PluginHelpers() nv = NewsVideos() nls = NewsLiveStreams() nwk = NewsWetterKarten() nuwz = NewsUWZ() nb = NewsBuli() nf = NewsFeed() if len(sys.argv) == 3: addon_handle = int(sys.argv[1]) params = ph.parameters_string_to_dict(sys.argv[2]) methode = urllib.unquote_plus(params.get('methode', '')) buliliga = urllib.unquote_plus(params.get('buliliga', '')) url = urllib.unquote_plus(params.get('url', '')) headerpic = urllib.unquote_plus(params.get('headerpic', '')) clickable = urllib.unquote_plus(params.get('clickable', '')) elif len(sys.argv) > 1: params = ph.parameters_string_to_dict(sys.argv[1]) methode = urllib.unquote_plus(params.get('methode', '')) buliliga = urllib.unquote_plus(params.get('buliliga', '')) url = urllib.unquote_plus(params.get('url', '')) headerpic = urllib.unquote_plus(params.get('headerpic', '')) clickable = urllib.unquote_plus(params.get('clickable', '')) else: methode = None buliliga = 1
# Create Objects ph = PluginHelpers() nv = NewsVideos() nls = NewsLiveStreams() nwk = NewsWetterKarten() nuwz = NewsUWZ() nb = NewsBuli() nf = NewsFeed() if len(sys.argv)==3: addon_handle = int(sys.argv[1]) params = ph.parameters_string_to_dict(sys.argv[2]) methode = urllib.unquote_plus(params.get('methode', '')) buliliga = urllib.unquote_plus(params.get('buliliga', '')) url = urllib.unquote_plus(params.get('url', '')) headerpic = urllib.unquote_plus(params.get('headerpic', '')) clickable = urllib.unquote_plus(params.get('clickable', '')) elif len(sys.argv)>1: params = ph.parameters_string_to_dict(sys.argv[1]) methode = urllib.unquote_plus(params.get('methode', '')) buliliga = urllib.unquote_plus(params.get('buliliga', '')) url = urllib.unquote_plus(params.get('url', '')) headerpic = urllib.unquote_plus(params.get('headerpic', '')) clickable = urllib.unquote_plus(params.get('clickable', '')) else: methode = None buliliga = 1