Skip to content

Commit 7c0e6e5

Browse files
MarkDavenyblink1073
authored andcommitted
chore: fix some comments and typos (mongodb#1623)
Signed-off-by: MarkDaveny <[email protected]> (cherry picked from commit 925db11)
1 parent b50f397 commit 7c0e6e5

File tree

8 files changed

+8
-8
lines changed

8 files changed

+8
-8
lines changed

etc/compile_check.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ function version {
1212
echo "$@" | awk -F. '{ printf("%d%03d%03d%03d\n", $1,$2,$3,$4); }';
1313
}
1414

15-
# compile_check will attempt to build the the internal/test/compilecheck project
15+
# compile_check will attempt to build the internal/test/compilecheck project
1616
# using the provided Go version. This is to simulate an end-to-end use case.
1717
# This check will only run on environments where the Go version is greater than
1818
# or equal to the given version.

mongo/options/mongooptions.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ const (
102102
// UpdateLookup includes a delta describing the changes to the document and a copy of the entire document that
103103
// was changed.
104104
UpdateLookup FullDocument = "updateLookup"
105-
// WhenAvailable includes a post-image of the the modified document for replace and update change events
105+
// WhenAvailable includes a post-image of the modified document for replace and update change events
106106
// if the post-image for this event is available.
107107
WhenAvailable FullDocument = "whenAvailable"
108108
)

mongo/writeconcern/writeconcern.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ var ErrNegativeWTimeout = errors.New("write concern `wtimeout` field cannot be n
5151
type WriteConcern struct {
5252
// W requests acknowledgment that the write operation has propagated to a
5353
// specified number of mongod instances or to mongod instances with
54-
// specified tags. It sets the the "w" option in a MongoDB write concern.
54+
// specified tags. It sets the "w" option in a MongoDB write concern.
5555
//
5656
// W values must be a string or an int.
5757
//

x/mongo/driver/auth/speculative_x509_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ func createSpeculativeX509Handshake() []bsoncore.Document {
130130
return []bsoncore.Document{hello}
131131
}
132132

133-
// createSpeculativeX509Handshake creates the server replies for a handshake + X509 authentication attempt.
133+
// createRegularX509Handshake creates the server replies for a handshake + X509 authentication attempt.
134134
// There are two replies:
135135
//
136136
// 1. hello reply

x/mongo/driver/operation.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -599,7 +599,7 @@ func (op Operation) Execute(ctx context.Context) error {
599599
}
600600
}()
601601
for {
602-
// If we're starting a retry and the the error from the previous try was
602+
// If we're starting a retry and the error from the previous try was
603603
// a context canceled or deadline exceeded error, stop retrying and
604604
// return that error.
605605
if errors.Is(prevErr, context.Canceled) || errors.Is(prevErr, context.DeadlineExceeded) {

x/mongo/driver/operation_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ func TestOperation(t *testing.T) {
7979
_, err := op.selectServer(context.Background(), 1, nil)
8080
noerr(t, err)
8181

82-
// Assert the the selector is an operation selector wrapper.
82+
// Assert the selector is an operation selector wrapper.
8383
oss, ok := d.params.selector.(*opServerSelector)
8484
require.True(t, ok)
8585

x/mongo/driver/topology/polling_srv_records_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ func TestPollingSRVRecordsLoadBalanced(t *testing.T) {
309309

310310
func TestPollSRVRecordsMaxHosts(t *testing.T) {
311311
// simulateSRVPoll creates a topology with srvMaxHosts, mocks the DNS changes described by
312-
// recordsToAdd and recordsToRemove, and returns the the topology.
312+
// recordsToAdd and recordsToRemove, and returns the topology.
313313
simulateSRVPoll := func(srvMaxHosts int, recordsToAdd []*net.SRV, recordsToRemove []*net.SRV) (*Topology, func(ctx context.Context) error) {
314314
t.Helper()
315315

x/mongo/driver/wiremessage/wiremessage.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -486,7 +486,7 @@ func ReadReplyCursorID(src []byte) (cursorID int64, rem []byte, ok bool) {
486486
return readi64(src)
487487
}
488488

489-
// ReadReplyStartingFrom reads the starting from from src.
489+
// ReadReplyStartingFrom reads the starting from src.
490490
func ReadReplyStartingFrom(src []byte) (startingFrom int32, rem []byte, ok bool) {
491491
return readi32(src)
492492
}

0 commit comments

Comments
 (0)