summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoretobi <git@e-tobi.net>2011-10-09 09:32:18 (GMT)
committeretobi <git@e-tobi.net>2011-10-09 17:21:30 (GMT)
commiteae93b298f519d67edb10999e1abd1c11c8928be (patch)
tree244604e18e71827c8cbc08df3b088e1888cc5b6f
parent0b19d02c1bddea73bec8057a6a2bf52199fedc45 (diff)
downloadvdrnfofs-eae93b298f519d67edb10999e1abd1c11c8928be.tar.gz
vdrnfofs-eae93b298f519d67edb10999e1abd1c11c8928be.tar.bz2
Prefer VDR 1.7 recordings over VDR 1.6 recordings
-rw-r--r--vdrnfofs/filesystemnodes.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/vdrnfofs/filesystemnodes.py b/vdrnfofs/filesystemnodes.py
index 07eec7e..99783d0 100644
--- a/vdrnfofs/filesystemnodes.py
+++ b/vdrnfofs/filesystemnodes.py
@@ -65,9 +65,9 @@ class MpgNode:
def mpeg_files(self):
if not self._mpeg_files:
- self._mpeg_files = glob.glob(self.path + '/[0-9]*.vdr')
+ self._mpeg_files = glob.glob(self.path + '/[0-9]*.ts')
if not self._mpeg_files:
- self._mpeg_files = glob.glob(self.path + '/[0-9]*.ts')
+ self._mpeg_files = glob.glob(self.path + '/[0-9]*.vdr')
self._mpeg_files.sort()
return self._mpeg_files
@@ -112,12 +112,12 @@ class NfoNode:
def nfo_content(self):
if not self._nfo_content:
- if os.path.exists(self.path + '/info.vdr'):
- info_vdr = InfoVdr(self.path + '/info.vdr')
- elif os.path.exists(self.path + '/info'):
- info_vdr = InfoVdr(self.path + '/info')
- else:
- info_vdr = InfoVdr()
+ info_path = self.path + '/info'
+ if not os.path.exists(info_path):
+ info_path = self.path + '/info.vdr'
+ if not os.path.exists(info_path):
+ info_path = None
+ info_vdr = InfoVdr(info_path)
self._nfo_content = """<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<movie>
<title>%s</title>