From c27d3edaa5b69919a8489d5c144d2d91d671e9b4 Mon Sep 17 00:00:00 2001 From: lowlighter <22963968+lowlighter@users.noreply.github.com> Date: Mon, 26 Oct 2020 14:04:04 +0100 Subject: [PATCH] Update action --- action/dist/index.js | 6 +++--- src/plugins/music/index.mjs | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/action/dist/index.js b/action/dist/index.js index 91a266ee..6e384909 100644 --- a/action/dist/index.js +++ b/action/dist/index.js @@ -362,11 +362,11 @@ var E_Users_lecoq_Documents_GitHub_gitstats_node_modules_axios_index_default = / } //Parameters override and checks - let {"music.provider":provider = null, "music.mode":mode = null, "music.playlist":playlist = null, "music.limit":limit = 4} = q + let {"music.provider":provider = "", "music.mode":mode = "", "music.playlist":playlist = null, "music.limit":limit = 4} = q //Auto-guess parameters - if ((playlist)&&(mode === null)) + if ((playlist)&&(!mode)) mode = "playlist" - if ((playlist)&&(provider === null)) + if ((playlist)&&(!provider)) for (const [name, {embed}] of Object.entries(providers)) if (embed.test(playlist)) provider = name diff --git a/src/plugins/music/index.mjs b/src/plugins/music/index.mjs index 19e0c5d6..80e25991 100644 --- a/src/plugins/music/index.mjs +++ b/src/plugins/music/index.mjs @@ -30,11 +30,11 @@ } //Parameters override and checks - let {"music.provider":provider = null, "music.mode":mode = null, "music.playlist":playlist = null, "music.limit":limit = 4} = q + let {"music.provider":provider = "", "music.mode":mode = "", "music.playlist":playlist = null, "music.limit":limit = 4} = q //Auto-guess parameters - if ((playlist)&&(mode === null)) + if ((playlist)&&(!mode)) mode = "playlist" - if ((playlist)&&(provider === null)) + if ((playlist)&&(!provider)) for (const [name, {embed}] of Object.entries(providers)) if (embed.test(playlist)) provider = name