From 5544dfd2fe81641c8a4bba826c1dcd0e63290406 Mon Sep 17 00:00:00 2001 From: tomkat83 Date: Sun, 29 May 2016 20:03:31 +0200 Subject: [PATCH] Fix DTS-HD audio is not correctly identified - Fixes #42 - You need to reset the Kodi DB to take advantage --- resources/lib/PlexAPI.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/lib/PlexAPI.py b/resources/lib/PlexAPI.py index 87c87c66..98e612fc 100644 --- a/resources/lib/PlexAPI.py +++ b/resources/lib/PlexAPI.py @@ -1809,8 +1809,8 @@ class API(): elif mediaType == 2: # Audio streams audiotrack = {} audiotrack['codec'] = mediaStream['codec'].lower() - profile = mediaStream.get('codecID', '').lower() - if "dca" in audiotrack['codec'] and "dts-hd ma" in profile: + if ("dca" in audiotrack['codec'] and + "ma" in mediaStream.get('profile', '').lower()): audiotrack['codec'] = "dtshd_ma" audiotrack['channels'] = mediaStream.get('channels') # 'unknown' if we cannot get language