From 1c68dace8d3a5c9c89d69d3b54d2485679ccb67f Mon Sep 17 00:00:00 2001 From: samhippo <63636707+samhippo@users.noreply.github.com> Date: Sat, 23 May 2020 02:24:08 -0700 Subject: [PATCH] Update playlist-sort.lua --- playlist-sort.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/playlist-sort.lua b/playlist-sort.lua index 7f2e8ca..23d63db 100644 --- a/playlist-sort.lua +++ b/playlist-sort.lua @@ -43,6 +43,9 @@ end local function main(type,asc) local dt = nil + if(type == nil) then type = "name" end + if(asc == nil) then asc = "asc" end + if(type == "date") then dt = getDate() elseif(type == "size") then @@ -59,6 +62,7 @@ local function main(type,asc) mp.commandv('loadfile',n.filename,'append') end end + mp.osd_message("Playlist Sort: "..type.." "..asc) end mp.register_script_message("playlist-sort", main)