Commit d533b59e authored by Max Kellermann's avatar Max Kellermann

PlaylistFile: switch spl_append_uri() arguments

Playlist file name first, to be consistent with the other functions in this library.
parent 5ad2980d
...@@ -402,7 +402,7 @@ spl_append_song(const char *utf8path, const DetachedSong &song, Error &error) ...@@ -402,7 +402,7 @@ spl_append_song(const char *utf8path, const DetachedSong &song, Error &error)
} }
bool bool
spl_append_uri(const char *url, const char *utf8file, Error &error) spl_append_uri(const char *utf8file, const char *url, Error &error)
{ {
if (uri_has_scheme(url)) { if (uri_has_scheme(url)) {
return spl_append_song(utf8file, DetachedSong(url), return spl_append_song(utf8file, DetachedSong(url),
......
...@@ -71,7 +71,7 @@ bool ...@@ -71,7 +71,7 @@ bool
spl_append_song(const char *utf8path, const DetachedSong &song, Error &error); spl_append_song(const char *utf8path, const DetachedSong &song, Error &error);
bool bool
spl_append_uri(const char *file, const char *utf8file, Error &error); spl_append_uri(const char *path_utf8, const char *uri_utf8, Error &error);
bool bool
spl_rename(const char *utf8from, const char *utf8to, Error &error); spl_rename(const char *utf8from, const char *utf8to, Error &error);
......
...@@ -194,7 +194,7 @@ handle_playlistadd(Client &client, gcc_unused int argc, char *argv[]) ...@@ -194,7 +194,7 @@ handle_playlistadd(Client &client, gcc_unused int argc, char *argv[])
return CommandResult::ERROR; return CommandResult::ERROR;
} }
success = spl_append_uri(uri, playlist, error); success = spl_append_uri(playlist, uri, error);
} else { } else {
#ifdef ENABLE_DATABASE #ifdef ENABLE_DATABASE
success = search_add_to_playlist(uri, playlist, nullptr, success = search_add_to_playlist(uri, playlist, nullptr,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment