Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

remove useless if (#7183)

p0ny3eaafb0c4328
diff --git a/backend/plugin/db/pg/sync.go b/backend/plugin/db/pg/sync.go
index 4e64504aa7..109b837c5c 100644
--- a/backend/plugin/db/pg/sync.go
+++ b/backend/plugin/db/pg/sync.go
@@ -591,9 +591,6 @@ func getIndexes(txn *sql.Tx) (map[db.TableKey][]*storepb.IndexMetadata, error) {
index.Type = getIndexMethodType(statement)
index.Unique = node.Index.Unique
index.Expressions = node.Index.GetKeyNameList()
- if err != nil {
- return nil, err
- }
if primary.Valid && primary.Int32 == 1 {
index.Primary = true
}