diff --git a/openapi/owprov.yaml b/openapi/owprov.yaml index 0b61af6..de07df7 100644 --- a/openapi/owprov.yaml +++ b/openapi/owprov.yaml @@ -1112,16 +1112,6 @@ components: defaultOperator: type: boolean default: false - locations: - type: array - items: - type: string - format: uuid - contacts: - type: array - items: - type: string - format: uuid rrm: type: string enum: diff --git a/src/RESTAPI/RESTAPI_op_contact_handler.cpp b/src/RESTAPI/RESTAPI_op_contact_handler.cpp index f038adc..0897e2a 100644 --- a/src/RESTAPI/RESTAPI_op_contact_handler.cpp +++ b/src/RESTAPI/RESTAPI_op_contact_handler.cpp @@ -62,10 +62,9 @@ namespace OpenWifi { } void RESTAPI_op_contact_handler::DoPut() { - auto uuid = GetBinding("uuid",""); - + auto uuid = GetBinding("uuid"); OpContactDB::RecordName Existing; - if(uuid.empty() || DB_.GetRecord("id",uuid,Existing)) { + if(uuid.empty() || !DB_.GetRecord("id",uuid,Existing)) { return BadRequest(RESTAPI::Errors::MissingUUID); } diff --git a/src/RESTAPI/RESTAPI_op_location_handler.cpp b/src/RESTAPI/RESTAPI_op_location_handler.cpp index d1153be..5da8327 100644 --- a/src/RESTAPI/RESTAPI_op_location_handler.cpp +++ b/src/RESTAPI/RESTAPI_op_location_handler.cpp @@ -61,10 +61,9 @@ namespace OpenWifi { } void RESTAPI_op_location_handler::DoPut() { - auto uuid = GetBinding("uuid",""); - + auto uuid = GetBinding("uuid"); OpLocationDB::RecordName Existing; - if(uuid.empty() || DB_.GetRecord("id",uuid,Existing)) { + if(uuid.empty() || !DB_.GetRecord("id",uuid,Existing)) { return BadRequest(RESTAPI::Errors::MissingUUID); } diff --git a/src/RESTAPI/RESTAPI_operators_handler.cpp b/src/RESTAPI/RESTAPI_operators_handler.cpp index 27989f9..1a2c9b2 100644 --- a/src/RESTAPI/RESTAPI_operators_handler.cpp +++ b/src/RESTAPI/RESTAPI_operators_handler.cpp @@ -98,7 +98,7 @@ namespace OpenWifi { return ReturnObject(Answer); } - return InternalError("Failed creating operatpr."); + return InternalError("Failed creating operator."); } void RESTAPI_operators_handler::DoPut() { diff --git a/src/storage/storage_sub_devices.cpp b/src/storage/storage_sub_devices.cpp index 48a32ac..52f4ded 100644 --- a/src/storage/storage_sub_devices.cpp +++ b/src/storage/storage_sub_devices.cpp @@ -110,3 +110,12 @@ template<> void ORM::DB< OpenWifi::SubDeviceDBRecordType, OpenWifi::ProvObjec Out.set<21>(In.suspended); Out.set<22>(In.realMacAddress); } + + +/* + +$ cmake3 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr -DLibCrypto_INCLUDE_DIR=/usr/include -DLibCrypto_LIBRARY=/usr/lib64/libcrypto.so .. + + + + */ \ No newline at end of file