GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Passed
Push — master ( a09f1e...f8a689 )
by David
01:26
created

getSetting()   A

Complexity

Conditions 2

Size

Total Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 2
c 1
b 0
f 0
dl 0
loc 6
rs 9.4285
1
#!/usr/bin/python
2
# -*- coding: UTF-8 -*-
3
"""
4
Utils module. Some basic functions that maybe I'll need more than once
5
"""
6
import sys
7
import xbmc, xbmcaddon
8
__addon__ = xbmcaddon.Addon("script.simkl")
9
10
def getstr(strid):
11
    """ Given an id, returns the localized string """
12
    return __addon__.getLocalizedString(strid)
13
14
def getSetting(settingid):
15
    """ Given an id, return the setting """
16
    ret = __addon__.getSetting(settingid)
17
    xbmc.log("Simkl: {0}: {1}".format(settingid, ret))
18
    if ret == "false": ret = False
19
    return ret