Skip to content

Commit f5007cf

Browse files
committed
store temp files extensionless
1 parent 6c653fc commit f5007cf

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

Diff for: lib/_included_packages/plexnet/plexplayer.py

-1
Original file line numberDiff line numberDiff line change
@@ -608,7 +608,6 @@ def build(self, item=None):
608608
path = part.key or part.thumb
609609
server = item.getServer()
610610

611-
obj.path = path
612611
obj.url = server.buildUrl(path, True)
613612
obj.enableBlur = server.supportsPhotoTranscoding
614613

Diff for: lib/windows/photos.py

+4-5
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ def _showPhoto(self):
297297
if isCurrent and not self.initialLoad:
298298
self.setBoolProperty('is.updating', True)
299299

300-
path, background = self.getCachedPhotoData(meta.path, url, bgURL)
300+
path, background = self.getCachedPhotoData(url, bgURL)
301301
if not (path and background):
302302
return
303303

@@ -327,14 +327,13 @@ def _showPhoto(self):
327327
finally:
328328
self.setBoolProperty('is.updating', False)
329329

330-
def getCachedPhotoData(self, path, url, bgURL):
330+
def getCachedPhotoData(self, url, bgURL):
331331
if not url:
332332
return
333333

334-
ext = os.path.splitext(path)[1]
335334
basename = hashlib.sha1(url).hexdigest()
336-
tmpPath = os.path.join(self.tempFolder, basename + ext)
337-
tmpBgPath = os.path.join(self.tempFolder, "%s_bg%s" % (basename, ext))
335+
tmpPath = os.path.join(self.tempFolder, basename)
336+
tmpBgPath = os.path.join(self.tempFolder, "%s_bg" % basename)
338337

339338
for p, url in ((tmpPath, url), (tmpBgPath, bgURL)):
340339
if not os.path.exists(p):# and not xbmc.getCacheThumbName(tmpFn):

0 commit comments

Comments
 (0)