command/DatabaseCommands: pass URI to handle_lsinfo2()
This commit is contained in:
parent
81ce684b35
commit
76f85e6f7b
|
@ -52,11 +52,8 @@ handle_listfiles_db(Client &client, Response &r, const char *uri)
|
|||
}
|
||||
|
||||
CommandResult
|
||||
handle_lsinfo2(Client &client, Request args, Response &r)
|
||||
handle_lsinfo2(Client &client, const char *uri, Response &r)
|
||||
{
|
||||
/* default is root directory */
|
||||
const auto uri = args.GetOptional(0, "");
|
||||
|
||||
const DatabaseSelection selection(uri, false);
|
||||
|
||||
Error error;
|
||||
|
|
|
@ -30,7 +30,7 @@ CommandResult
|
|||
handle_listfiles_db(Client &client, Response &r, const char *uri);
|
||||
|
||||
CommandResult
|
||||
handle_lsinfo2(Client &client, Request request, Response &response);
|
||||
handle_lsinfo2(Client &client, const char *uri, Response &response);
|
||||
|
||||
CommandResult
|
||||
handle_find(Client &client, Request request, Response &response);
|
||||
|
|
|
@ -200,7 +200,7 @@ handle_lsinfo(Client &client, Request args, Response &r)
|
|||
}
|
||||
|
||||
#ifdef ENABLE_DATABASE
|
||||
CommandResult result = handle_lsinfo2(client, args, r);
|
||||
CommandResult result = handle_lsinfo2(client, uri, r);
|
||||
if (result != CommandResult::OK)
|
||||
return result;
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue