mirror of https://github.com/citusdata/citus.git
Rearrange code when managing privileges on tables.
Precisely, I moved the check for cols presence a bit later. It's safe to exit with ERROR after having append to the string and it will ease the reading of next commit.pull/7918/head
parent
a7e686c106
commit
b634193e00
|
@ -90,16 +90,16 @@ PreprocessGrantStmt(Node *node, const char *queryString,
|
||||||
}
|
}
|
||||||
isFirst = false;
|
isFirst = false;
|
||||||
|
|
||||||
|
Assert(priv->priv_name != NULL);
|
||||||
|
|
||||||
|
appendStringInfo(&privsString, "%s", priv->priv_name);
|
||||||
|
|
||||||
if (priv->cols != NIL)
|
if (priv->cols != NIL)
|
||||||
{
|
{
|
||||||
ereport(ERROR, (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
|
ereport(ERROR, (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
|
||||||
errmsg("grant/revoke on column list is currently "
|
errmsg("grant/revoke on column list is currently "
|
||||||
"unsupported")));
|
"unsupported")));
|
||||||
}
|
}
|
||||||
|
|
||||||
Assert(priv->priv_name != NULL);
|
|
||||||
|
|
||||||
appendStringInfo(&privsString, "%s", priv->priv_name);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue