chore: use errors.New to replace fmt.Errorf with no parameters will much better (#4778)

This commit is contained in:
Andi 2024-08-28 12:45:57 +08:00 committed by GitHub
parent 27aef4ac2e
commit ae1841efb0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -89,7 +89,7 @@ func (i *Importer) fileJSONToFile(ctx context.Context, fileJSON jsonschema.DirEn
return i.baseFileJSONToBaseFile(ctx, ff)
}
return nil, fmt.Errorf("unknown file type")
return nil, errors.New("unknown file type")
}
func (i *Importer) baseFileJSONToBaseFile(ctx context.Context, baseJSON *jsonschema.BaseFile) (*models.BaseFile, error) {