Skip to content

Commit

Permalink
refactor(i): Delete dead code in db.addSchema func (#2246)
Browse files Browse the repository at this point in the history
## Relevant issue(s)
Resolves #2251

## Description
Seems like dead code. Not sure if this was the outcome of a partial
implementation or just some code that wasn't removed before being
merged.
  • Loading branch information
shahzadlone authored and nasdf committed Jan 23, 2024
1 parent ed6eafd commit ba76a1f
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions db/schema.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,6 @@ func (db *db) addSchema(
txn datastore.Txn,
schemaString string,
) ([]client.CollectionDescription, error) {
existingCollections, err := db.getAllCollections(ctx, txn)
if err != nil {
return nil, err
}

existingDefinitions := make([]client.CollectionDefinition, len(existingCollections))
for i := range existingCollections {
existingDefinitions[i] = existingCollections[i].Definition()
}

newDefinitions, err := db.parser.ParseSDL(ctx, schemaString)
if err != nil {
return nil, err
Expand Down

0 comments on commit ba76a1f

Please sign in to comment.