diff --git a/source/rename_file/changelog.md b/source/rename_file/changelog.md index d388d4271..dd006223a 100644 --- a/source/rename_file/changelog.md +++ b/source/rename_file/changelog.md @@ -1,4 +1,7 @@ +**0.0.11** +- fix error in channels test - should be int not str + **0.0.10** - fix error in replace function variable - vrezh->vrez_height diff --git a/source/rename_file/info.json b/source/rename_file/info.json index 9859b1068..6af72852c 100644 --- a/source/rename_file/info.json +++ b/source/rename_file/info.json @@ -11,5 +11,5 @@ "on_postprocessor_task_results": 0 }, "tags": "rename, postprocessor", - "version": "0.0.10" + "version": "0.0.11" } diff --git a/source/rename_file/plugin.py b/source/rename_file/plugin.py index e5f48b358..b02c52857 100644 --- a/source/rename_file/plugin.py +++ b/source/rename_file/plugin.py @@ -191,7 +191,10 @@ def append(data, settings, abspath, streams): channel_layout = '' logger.info("Not including channel layout - could not extract channel layout from file: '{}'".format(abspath)) else: - if "(side)" in channel_layout: channel_layout = channel_layout.replace("(side)","") + if "(side)" in channel_layout: + channel_layout = channel_layout.replace("(side)","") + elif: channel_layout == "stereo": + channel_layout = "2.0" else: channel_layout = '' @@ -293,7 +296,7 @@ def replace(data, settings, abspath, streams): audio_codec = streams[astream]["codec_name"] channel_layout = streams[astream]["channel_layout"] channels = streams[astream]["channels"] - if channel_layout == "stereo" and channels == '2': + if channel_layout == "stereo" and channels == 2: acodec = audio_codec + ' ' + str(channels) + '.0' elif channels > 4: acodec = audio_codec + ' ' + str(channel_layout).replace('(side)','')