fix set_property aid cannot be set to nil

If you attempt to set_property("aid", nil) the script will throw an error.
This commit is contained in:
0xACE 2020-01-17 04:09:43 +00:00 committed by zenyd
parent 4c237b17cf
commit 34b3ccefa1
1 changed files with 1 additions and 1 deletions

View File

@ -23,7 +23,7 @@ function restore_normalspeed()
if mp.get_property_native("video-sync") == "desync" then
mp.set_property("video-sync", "audio")
end
if aid~=mp.get_property("aid") then mp.set_property("aid", aid) end
if (aid~=nil and aid~=mp.get_property("aid")) then mp.set_property("aid", aid) end
end
function check_should_speedup()