From 575fbad254a1ce67530bf2aedc9852c89c072c3f Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sat, 25 Oct 2014 23:49:35 +0200 Subject: AllCommands: "commands" returns playlist commands only if playlist_directory configured --- src/command/PlaylistCommands.cxx | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/command/PlaylistCommands.cxx') diff --git a/src/command/PlaylistCommands.cxx b/src/command/PlaylistCommands.cxx index c2b18064c..593eab865 100644 --- a/src/command/PlaylistCommands.cxx +++ b/src/command/PlaylistCommands.cxx @@ -35,9 +35,17 @@ #include "protocol/ArgParser.hxx" #include "protocol/Result.hxx" #include "ls.hxx" +#include "Mapper.hxx" +#include "fs/AllocatedPath.hxx" #include "util/UriUtil.hxx" #include "util/Error.hxx" +bool +playlist_commands_available() +{ + return !map_spl_path().IsNull(); +} + static void print_spl_list(Client &client, const PlaylistVector &list) { -- cgit v1.2.3