Skip to content

Commit 347c47d

Browse files
committed
lint
1 parent c14fe1c commit 347c47d

File tree

5 files changed

+5
-11
lines changed

5 files changed

+5
-11
lines changed

src/operations/aggregate.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import { type Connection } from '..';
21
import type { Document } from '../bson';
32
import { CursorResponse, ExplainedCursorResponse } from '../cmap/wire_protocol/responses';
43
import { type CursorTimeoutMode } from '../cursor/abstract_cursor';
@@ -106,7 +105,7 @@ export class AggregateOperation extends CommandOperation<CursorResponse> {
106105
this.pipeline.push(stage);
107106
}
108107

109-
override buildCommandDocument(connection: Connection): Document {
108+
override buildCommandDocument(): Document {
110109
const options = this.options;
111110
const command: Document = { aggregate: this.target, pipeline: this.pipeline };
112111

src/operations/find_and_modify.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ export class FindAndModifyOperation extends CommandOperation<Document> {
188188
command.comment = options.comment;
189189
}
190190

191-
decorateWithCollation(command, this.collection, options);
191+
decorateWithCollation(command, options);
192192

193193
if (options.hint) {
194194
const unacknowledgedWrite = this.writeConcern?.w === 0;

src/sdam/server_selection.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { MongoCompatibilityError, MongoInvalidArgumentError } from '../error';
1+
import { MongoInvalidArgumentError } from '../error';
22
import { ReadPreference } from '../read_preference';
33
import { ServerType, TopologyType } from './common';
44
import type { ServerDescription, TagSet } from './server_description';
@@ -273,7 +273,6 @@ export function readPreferenceServerSelector(readPreference: ReadPreference): Se
273273
servers: ServerDescription[],
274274
deprioritized: ServerDescription[] = []
275275
): ServerDescription[] {
276-
277276
if (topologyDescription.type === TopologyType.LoadBalanced) {
278277
return servers.filter(loadBalancerFilter);
279278
}

src/sessions.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import { Binary, type Document, Long, type Timestamp } from './bson';
22
import type { CommandOptions, Connection } from './cmap/connection';
33
import { ConnectionPoolMetrics } from './cmap/metrics';
44
import { type MongoDBResponse } from './cmap/wire_protocol/responses';
5-
import { isSharded } from './cmap/wire_protocol/shared';
65
import { PINNED, UNPINNED } from './constants';
76
import type { AbstractCursor } from './cursor/abstract_cursor';
87
import {

src/utils.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ import type { Db } from './db';
1919
import {
2020
type AnyError,
2121
MongoAPIError,
22-
MongoCompatibilityError,
2322
MongoInvalidArgumentError,
2423
MongoNetworkTimeoutError,
2524
MongoNotConnectedError,
@@ -207,12 +206,10 @@ export function isPromiseLike<T = unknown>(value?: unknown): value is PromiseLik
207206
* @param options - options containing collation settings
208207
*/
209208
export function decorateWithCollation(
210-
command: Document,
211-
target: MongoClient | Db | Collection,
212-
options: AnyOptions
209+
command: Document, options: AnyOptions
213210
): void {
214211
if (options.collation && typeof options.collation === 'object') {
215-
command.collation = options.collation;
212+
command.collation = options.collation;
216213
}
217214
}
218215

0 commit comments

Comments
 (0)