Merge pull request #7739 from eveneast/main

Fix some comments
This commit is contained in:
Tim Sehn
2024-04-15 10:17:44 -07:00
committed by GitHub
7 changed files with 8 additions and 8 deletions

View File

@@ -322,7 +322,7 @@ func handleCommitErr(sqlCtx *sql.Context, queryist cli.Queryist, err error, usag
if actions.IsTblInConflict(err) {
inConflict := actions.GetTablesForError(err)
bdr := errhand.BuildDError(`tables %v have unresolved conflicts from the merge. resolve the conflicts before commiting`, inConflict)
bdr := errhand.BuildDError(`tables %v have unresolved conflicts from the merge. resolve the conflicts before committing`, inConflict)
return HandleVErrAndExitCode(bdr.Build(), usage)
}

View File

@@ -704,7 +704,7 @@ func getImportSchema(ctx context.Context, dEnv *env.DoltEnv, impOpts *importOpti
if impOpts.operation == mvdata.CreateOp {
if impOpts.srcIsStream() {
// todo: capture stream data to file so we can use schema inferrence
// todo: capture stream data to file so we can use schema inference
return nil, nil
}

View File

@@ -153,7 +153,7 @@ func deserializeFlatbufferForeignKeys(msg types.SerialMessage) (*ForeignKeyColle
return collection, nil
}
// serializeNomsForeignKeys serializes a ForeignKeyCollection as a types.Map.
// serializeFlatbufferForeignKeys serializes a ForeignKeyCollection as a types.Map.
func serializeFlatbufferForeignKeys(fkc *ForeignKeyCollection) types.SerialMessage {
foreignKeys := fkc.AllKeys()
offsets := make([]fb.UOffsetT, len(foreignKeys))

View File

@@ -49,7 +49,7 @@ const (
Ignore IgnoreResult = iota // The table should be ignored.
DontIgnore // The table should not be ignored.
IgnorePatternConflict // The table matched multiple conflicting patterns.
ErrorOccurred // An error occured.
ErrorOccurred // An error occurred.
)
type IgnorePatterns []IgnorePattern

View File

@@ -82,7 +82,7 @@ func getStashList(ctx context.Context, ds datas.Dataset, vrw types.ValueReadWrit
return sl, nil
}
// getStashList returns hash address only of the stash at given index.
// getStashHashAtIdx returns hash address only of the stash at given index.
func getStashHashAtIdx(ctx context.Context, ds datas.Dataset, ns tree.NodeStore, idx int) (hash.Hash, error) {
v, ok := ds.MaybeHead()
if !ok {
@@ -92,7 +92,7 @@ func getStashHashAtIdx(ctx context.Context, ds datas.Dataset, ns tree.NodeStore,
return datas.GetStashAtIdx(ctx, ns, v, idx)
}
// getStashList returns stash root value and head commit of a stash entry at given index.
// getStashAtIdx returns stash root value and head commit of a stash entry at given index.
func getStashAtIdx(ctx context.Context, ds datas.Dataset, vrw types.ValueReadWriter, ns tree.NodeStore, idx int) (*RootValue, *Commit, *datas.StashMeta, error) {
v, ok := ds.MaybeHead()
if !ok {

View File

@@ -227,7 +227,7 @@ type Query struct {
// |QueryResult| specifies assertions on the results of a |Query|. Columns must
// be specified for a |Query| and the query results must fully match. If Rows
// are ommited, anything is allowed as long as all rows are read successfully.
// are omitted, anything is allowed as long as all rows are read successfully.
// All assertions here are string equality.
type QueryResult struct {
Columns []string `yaml:"columns"`

View File

@@ -305,7 +305,7 @@ func IsValidRef(ctx context.Context, cSpecStr string, ddb *doltdb.DoltDB, rsr en
headRef, err := rsr.CWBHeadRef()
if err == doltdb.ErrOperationNotSupportedInDetachedHead {
// This is safe because ddb.Resolve checks if headRef is nil, but only when the value is actually needed.
// Basically, this guarentees that resolving "HEAD" or similar will return an error but other resolves will work.
// Basically, this guarantees that resolving "HEAD" or similar will return an error but other resolves will work.
headRef = nil
} else if err != nil {
return false, err