def formatTime(self, timestamp): if timestamp: format = xbmc.getRegion('time').replace(':%S', '').replace('%H%H', '%H') return timestamp.strftime(format) else: return ''