diff --git a/src/httpd_jsonapi.c b/src/httpd_jsonapi.c index 09984541..0d0df6ec 100644 --- a/src/httpd_jsonapi.c +++ b/src/httpd_jsonapi.c @@ -1230,10 +1230,16 @@ static int jsonapi_reply_update(struct httpd_request *hreq) { const char *param; + const char *param_path; param = httpd_query_value_find(hreq->query, "scan_kind"); + param_path = httpd_query_value_find(hreq->query, "path"); + + if (param_path) + library_rescan_path(param_path); + else + library_rescan(db_scan_kind_enum(param)); - library_rescan(db_scan_kind_enum(param)); return HTTP_NOCONTENT; }