Update WebApi.cpp

This commit is contained in:
KkemChen 2024-06-18 19:47:12 +08:00 committed by GitHub
parent bd9a7a78a2
commit 9fadcd275a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 0 deletions

View File

@ -1979,6 +1979,7 @@ void installWebApi() {
api_regist("/index/api/stack/stop", [](API_ARGS_MAP_ASYNC) { api_regist("/index/api/stack/stop", [](API_ARGS_MAP_ASYNC) {
CHECK_SECRET(); CHECK_SECRET();
CHECK_ARGS("id");
auto ret = VideoStackManager::Instance().stopVideoStack(allArgs["id"]); auto ret = VideoStackManager::Instance().stopVideoStack(allArgs["id"]);
val["code"] = ret; val["code"] = ret;
val["msg"] = ret ? "failed" : "success"; val["msg"] = ret ? "failed" : "success";