Skip to content

inconsistent await for endSession #1408

@ElectricNroff

Description

@ElectricNroff

https://github.com/CVEProject/cve-services/blob/54aa5ab9ab6ad8bad5f6d66fb867b2dd64c1bff4/src/controller/org.controller/org.controller.js
has several instances of await session.endSession() (e,g., in updateUser) but also several instances of session.endSession() (e.g., in createUser). Also, endSession is often called twice (e.g., before a return within a try when it is subsequently going to be executed within finally).

https://mongodb.github.io/node-mongodb-native/6.17/classes/ClientSession.html#endSession
@david-rocca

Metadata

Metadata

Assignees

Labels

user registryAn issue for the endpoints related to the User Registry

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions