mirror of
https://github.com/Telecominfraproject/wlan-cloud-ucentralgw.git
synced 2025-11-22 13:04:59 +00:00
Signed-off-by: stephb9959 <stephane.bourque@gmail.com>
This commit is contained in:
@@ -8,14 +8,14 @@
|
||||
|
||||
#include "RESTAPI_command.h"
|
||||
|
||||
#include "CommandManager.h"
|
||||
#include "StorageService.h"
|
||||
#include "framework/ow_constants.h"
|
||||
#include "CommandManager.h"
|
||||
|
||||
namespace OpenWifi {
|
||||
void RESTAPI_command::DoGet() {
|
||||
auto CommandUUID = GetBinding(RESTAPI::Protocol::COMMANDUUID, "");
|
||||
if(!Utils::ValidUUID(CommandUUID)) {
|
||||
if (!Utils::ValidUUID(CommandUUID)) {
|
||||
return NotFound();
|
||||
}
|
||||
|
||||
@@ -28,16 +28,16 @@ namespace OpenWifi {
|
||||
|
||||
void RESTAPI_command::DoDelete() {
|
||||
auto CommandUUID = GetBinding(RESTAPI::Protocol::COMMANDUUID, "");
|
||||
if(CommandUUID.empty()) {
|
||||
if (CommandUUID.empty()) {
|
||||
return BadRequest(RESTAPI::Errors::MissingUUID);
|
||||
}
|
||||
|
||||
if(!Utils::ValidUUID(CommandUUID)) {
|
||||
if (!Utils::ValidUUID(CommandUUID)) {
|
||||
return NotFound();
|
||||
}
|
||||
|
||||
GWObjects::CommandDetails C;
|
||||
if(!StorageService()->GetCommand(CommandUUID, C)) {
|
||||
GWObjects::CommandDetails C;
|
||||
if (!StorageService()->GetCommand(CommandUUID, C)) {
|
||||
return NotFound();
|
||||
}
|
||||
|
||||
@@ -47,4 +47,4 @@ namespace OpenWifi {
|
||||
}
|
||||
return InternalError(RESTAPI::Errors::NoRecordsDeleted);
|
||||
}
|
||||
}
|
||||
} // namespace OpenWifi
|
||||
Reference in New Issue
Block a user