Skip to content

Commit

Permalink
Hopefully fixed a compiler warning in gtihub actions
Browse files Browse the repository at this point in the history
  • Loading branch information
kzangeli committed Jan 29, 2022
1 parent 3916aa7 commit 31ae418
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/lib/orionld/serviceRoutines/orionldPatchAttribute.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -731,7 +731,7 @@ static KjNode* kjKeyValueTransformAttribute(KjNode* attrP, KjNode* dbAttributeP,
//
// 2. Set the valueNodeName according to the value of the type KjNode
//
char* valueNodeName;
char* valueNodeName = NULL;
if (strcmp(typeP->value.s, "Property") == 0) valueNodeName = (char*) "value";
else if (strcmp(typeP->value.s, "GeoProperty") == 0) valueNodeName = (char*) "value";
else if (strcmp(typeP->value.s, "Relationship") == 0) valueNodeName = (char*) "object";
Expand All @@ -742,6 +742,7 @@ static KjNode* kjKeyValueTransformAttribute(KjNode* attrP, KjNode* dbAttributeP,
LM_W(("Bad Input (invalid value of attribute type '%s')", typeP->value.s));
orionldState.httpStatusCode = 400;
orionldErrorResponseCreate(OrionldBadRequestData, "Invalid value of attribute type", typeP->value.s);
return NULL;
}
else
{
Expand Down

0 comments on commit 31ae418

Please sign in to comment.