From eb19a95f84cef8cc22959cd0aa74fa6d316bb271 Mon Sep 17 00:00:00 2001 From: Rafael Vargas Date: Tue, 28 Dec 2021 19:14:06 -0400 Subject: [PATCH] Removing useless if --- vulkanbot/music/Searcher.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/vulkanbot/music/Searcher.py b/vulkanbot/music/Searcher.py index c1f9a32..93795d7 100644 --- a/vulkanbot/music/Searcher.py +++ b/vulkanbot/music/Searcher.py @@ -17,16 +17,15 @@ class Searcher(): """ url_type = self.__identify_source(music) - if url_type == Provider.Name: - return [music] - - elif url_type == Provider.YouTube: - musics = self.__Youtube.search(music) - return musics + if url_type == Provider.YouTube: + return [music], Provider.YouTube elif url_type == Provider.Spotify: musics = self.__Spotify.search(music) - return musics + return musics, Provider.Name + + elif url_type == Provider.Name: + return [music], Provider.Name def __identify_source(self, music) -> Provider: """Identify the provider of a music"""