Skip to content

Commit 4b0670a

Browse files
committed
remove redundant PromiseLike casts
1 parent 8e352a8 commit 4b0670a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/hub/src/scope.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,7 @@ export class Scope implements ScopeInterface {
466466
} else {
467467
const result = processor({ ...event }, hint) as Event | null;
468468
if (isThenable(result)) {
469-
void (result as PromiseLike<Event | null>)
469+
void result
470470
.then(final => this._notifyEventProcessors(processors, final, hint, index + 1).then(resolve))
471471
.then(null, reject);
472472
} else {

packages/tracing/src/integrations/node/postgres.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ export class Postgres implements Integration {
8181
const rv = typeof values !== 'undefined' ? orig.call(this, config, values) : orig.call(this, config);
8282

8383
if (isThenable(rv)) {
84-
return (rv as Promise<unknown>).then((res: unknown) => {
84+
return rv.then((res: unknown) => {
8585
span?.finish();
8686
return res;
8787
});

0 commit comments

Comments
 (0)