Skip to content

Commit cfc91a0

Browse files
authored
refactor: remove unnecessary assertion (#1929)
1 parent 2bdadcd commit cfc91a0

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

src/matchers/mock/toBeRequestedWith.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@ const shortenJson = (
353353
keyLimit = KEY_LIMIT
354354
): ExpectWebdriverIO.JsonCompatible => {
355355
if (JSON.stringify(obj).length < lengthLimit) {
356-
return obj as ExpectWebdriverIO.JsonCompatible
356+
return obj
357357
}
358358

359359
if (Array.isArray(obj)) {

src/utils.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,6 @@ export const compareText = (
186186
}
187187
}
188188

189-
expected = expected as string | RegExp
190189
if (expected instanceof RegExp) {
191190
return {
192191
value: actual,

0 commit comments

Comments
 (0)