Skip to content

Fix typo from commited to committed #175

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions internal/raft/inflight_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ func TestInflight_StartCommit(t *testing.T) {
// Commit 3 times
in.Commit(1)
if in.Committed().Len() != 0 {
t.Fatalf("should not be commited")
t.Fatalf("should not be committed")
Copy link
Preview

Copilot AI May 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo corrected: ensure 'commited' is replaced with 'committed' in the error message.

Copilot uses AI. Check for mistakes.

}

in.Commit(1)
if in.Committed().Len() != 1 {
t.Fatalf("should be commited")
t.Fatalf("should be committed")
Copy link
Preview

Copilot AI May 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo corrected: ensure 'commited' is replaced with 'committed' in the error message.

Copilot uses AI. Check for mistakes.

}

// Already committed but should work anyways
Expand Down
2 changes: 1 addition & 1 deletion internal/raft/raft.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ var (
ErrUnknownPeer = errors.New("peer is unknown")

// ErrNothingNewToSnapshot is returned when trying to create a snapshot
// but there's nothing new commited to the FSM since we started.
// but there's nothing new committed to the FSM since we started.
Copy link
Preview

Copilot AI May 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo fix confirmed: the correction from 'commited' to 'committed' is correct.

Copilot uses AI. Check for mistakes.

ErrNothingNewToSnapshot = errors.New("Nothing new to snapshot")
)

Expand Down
2 changes: 1 addition & 1 deletion internal/raft/raft_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1390,7 +1390,7 @@ func TestRaft_ManualSnapshot(t *testing.T) {
defer c.Close()

leader := c.Leader()
// with nothing commited, asking for a snapshot should return an error
// with nothing committed, asking for a snapshot should return an error
ssErr := leader.Snapshot().Error()
if ssErr != ErrNothingNewToSnapshot {
t.Errorf("Attempt to manualy create snapshot should of errored because there's nothing to do: %v", ssErr)
Expand Down