mirror of https://github.com/citusdata/citus.git
Fixes review issues
parent
407909835f
commit
744ad45a49
|
@ -83,8 +83,6 @@ GetCommentForObject(Oid classOid, Oid objectOid)
|
||||||
scanKey);
|
scanKey);
|
||||||
if ((tuple = systable_getnext(scan)) != NULL)
|
if ((tuple = systable_getnext(scan)) != NULL)
|
||||||
{
|
{
|
||||||
Form_pg_shdescription shdesc = (Form_pg_shdescription) GETSTRUCT(tuple);
|
|
||||||
|
|
||||||
bool isNull = false;
|
bool isNull = false;
|
||||||
|
|
||||||
TupleDesc tupdesc = RelationGetDescr(shdescRelation);
|
TupleDesc tupdesc = RelationGetDescr(shdescRelation);
|
||||||
|
@ -92,19 +90,15 @@ GetCommentForObject(Oid classOid, Oid objectOid)
|
||||||
Datum descDatum = heap_getattr(tuple, Anum_pg_shdescription_description, tupdesc,
|
Datum descDatum = heap_getattr(tuple, Anum_pg_shdescription_description, tupdesc,
|
||||||
&isNull);
|
&isNull);
|
||||||
|
|
||||||
/* Check if the objoid matches the databaseOid */
|
|
||||||
if (shdesc->objoid == objectOid && shdesc->classoid == classOid)
|
/* Add the command to the list */
|
||||||
|
if (!isNull)
|
||||||
{
|
{
|
||||||
/* Add the command to the list */
|
comment = TextDatumGetCString(descDatum);
|
||||||
if (!isNull)
|
}
|
||||||
{
|
else
|
||||||
comment = TextDatumGetCString(descDatum);
|
{
|
||||||
}
|
comment = NULL;
|
||||||
else
|
|
||||||
{
|
|
||||||
comment = NULL;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue