Skip to content

Commit 99aef7c

Browse files
authored
chore: remove unnecessary if condition (#7354)
1 parent be8dc65 commit 99aef7c

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

packages/datadog-shimmer/src/shimmer.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -76,11 +76,8 @@ function wrapFunction (original, wrapper) {
7676
if (typeof original !== 'function') return original
7777

7878
const wrapped = wrapper(original)
79-
80-
if (typeof original === 'function') {
81-
assertNotClass(original)
82-
copyProperties(original, wrapped)
83-
}
79+
assertNotClass(original)
80+
copyProperties(original, wrapped)
8481

8582
return wrapped
8683
}

0 commit comments

Comments
 (0)