all: fix minor lint errors

Summary: Pull Request resolved: https://github.com/facebookincubator/ent/pull/159

Reviewed By: dlvhdr

Differential Revision: D18476131

fbshipit-source-id: 9e792f5a35f25233aad73f75f12d13d215a21ad2
This commit is contained in:
Ariel Mashraki
2019-11-13 06:00:26 -08:00
committed by Facebook Github Bot
parent a4f82f2331
commit 6ce4cb6803
5 changed files with 7 additions and 4 deletions

View File

@@ -4,7 +4,6 @@
// Package entc provides an interface for interacting with
// entc (ent codegen) as a package rather than an executable.
package entc
import (

View File

@@ -373,7 +373,7 @@ func (t Type) Describe(w io.Writer) {
io.WriteString(w, strings.ReplaceAll(b.String(), "\n", "\n\t")+"\n")
}
// NewIndex adds a new index for the given type table.
// AddIndex adds a new index for the type.
// It fails if the schema index is invalid.
func (t *Type) AddIndex(idx *load.Index) error {
index := &Index{Unique: idx.Unique}

View File

@@ -50,7 +50,7 @@ type Config struct {
Names []string
}
// Build loads the schemas package and build the Go plugin with this info.
// Load loads the schemas package and build the Go plugin with this info.
func (c *Config) Load() (*SchemaSpec, error) {
pkgPath, err := c.load()
if err != nil {