Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 546fbbd

Browse files
author
Nikita Glukhov
committed
Use JsonContainerXxx() macros instead of raw jsonb flags
1 parent 94650f7 commit 546fbbd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/backend/utils/adt/jsonpath_exec.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -188,11 +188,11 @@ JsonbType(JsonbValue *jb)
188188
{
189189
JsonbContainer *jbc = jb->val.binary.data;
190190

191-
if (jbc->header & JB_FSCALAR)
191+
if (JsonContainerIsScalar(jbc))
192192
type = jbvScalar;
193-
else if (jbc->header & JB_FOBJECT)
193+
else if (JsonContainerIsObject(jbc))
194194
type = jbvObject;
195-
else if (jbc->header & JB_FARRAY)
195+
else if (JsonContainerIsArray(jbc))
196196
type = jbvArray;
197197
else
198198
elog(ERROR, "Unknown container type: 0x%08x", jbc->header);

0 commit comments

Comments
 (0)