Skip to content

Commit 8b4a7f2

Browse files
authored
Drop session if release is not a string or is missing and log (#3396)
1 parent 1c2cdc3 commit 8b4a7f2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/core/src/baseclient.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,8 +152,8 @@ export abstract class BaseClient<B extends Backend, O extends Options> implement
152152
* @inheritDoc
153153
*/
154154
public captureSession(session: Session): void {
155-
if (!session.release) {
156-
logger.warn('Discarded session because of missing release');
155+
if (!(typeof session.release === 'string')) {
156+
logger.warn('Discarded session because of missing or non-string release');
157157
} else {
158158
this._sendSession(session);
159159
// After sending, we set init false to inidcate it's not the first occurence

0 commit comments

Comments
 (0)