260
Files Analyzed
15
Issues Found
11
Files with Issues

Issues by Rule

tjd/accurate-jsdoc
15

Issues by File

lib/document.js 3 issues
89:32 accurate-jsdoc

@param 'options': Object → { defaults?: boolean; skipId?: boolean; }. JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

740:31 accurate-jsdoc

@param 'opts': Object → { setters?: boolean; }. JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

5122:1 accurate-jsdoc

@returns: String|undefined → string. JSDoc includes null/undefined but TypeScript infers the value is always present. Either the code guarantees a value, or add runtime checks.

lib/helpers/document/applyTimestamps.js 3 issues
19:39 accurate-jsdoc

@param 'options': Object → { isUpdate?: boolean; currentTime?: Function; }. JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

38:49 accurate-jsdoc

@param 'options': Object → { isUpdate?: boolean; currentTime?: Function; }. JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

64:44 accurate-jsdoc

@param 'options': Object → { isUpdate?: boolean; currentTime?: Function; }. JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

lib/helpers/model/applyHooks.js 1 issue
123:1 accurate-jsdoc

@returns: { childModel: Model | typeof Subdocument, curType: Schema... → { childModel: any; curType: SchemaType; }. JSDoc declares union but TypeScript infers object.

lib/helpers/populate/assignVals.js 1 issue
267:43 accurate-jsdoc

@param 'populateOptions': Object → { transform?: Function; }. JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

lib/helpers/query/castUpdate.js 1 issue
216:42 accurate-jsdoc

@param 'options': Object → { strict?: string | boolean; }. JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

lib/model.js 1 issue
118:29 accurate-jsdoc

@param 'options': Object → { defaults?: boolean; skipId?: boolean; }. JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

lib/query.js 1 issue
4575:23 accurate-jsdoc

@param 'err': Error|undefined → Error. JSDoc includes null/undefined but TypeScript infers the value is always present. Either the code guarantees a value, or add runtime checks.

lib/schema/array.js 1 issue
45:27 accurate-jsdoc

@param 'cast': SchemaType → { (path: string, options?: SchemaTypeOptions, instance?: .... JSDoc declares unknown but TypeScript infers object.

lib/schema/documentArray.js 1 issue
545:36 accurate-jsdoc

@param 'init': Boolean|undefined → boolean. JSDoc includes null/undefined but TypeScript infers the value is always present. Either the code guarantees a value, or add runtime checks.

lib/types/documentArray/index.js 1 issue
30:1 accurate-jsdoc

@returns: MongooseDocumentArray → (values: any[], path: string, doc: Document, schematype: .... JSDoc declares unknown but TypeScript infers function.

lib/virtualType.js 1 issue
34:22 accurate-jsdoc

@param 'options': Object → { ref?: string | Function; localField?: string | Function.... JSDoc uses generic "object" but TypeScript infers a specific shape. Consider using @typedef to document the object structure.

Analyzed: 2/3/2026