Skip to content

Commit c2c222a

Browse files
refactor: avoid eslint no-empty-function warning
1 parent dc4d404 commit c2c222a

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/components/Tooltip/Tooltip.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -164,8 +164,7 @@ const Tooltip = ({
164164
}
165165

166166
if (!elementRefs.size) {
167-
// eslint-disable-next-line @typescript-eslint/no-empty-function
168-
return () => {}
167+
return () => null
169168
}
170169

171170
const enabledEvents: { event: string; listener: (event?: Event) => void }[] = []

src/components/TooltipController/TooltipController.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,7 @@ const TooltipController = ({
122122
}
123123

124124
if (!elementRefs.size) {
125-
// eslint-disable-next-line @typescript-eslint/no-empty-function
126-
return () => {}
125+
return () => null
127126
}
128127

129128
const observerCallback: MutationCallback = (mutationList) => {

0 commit comments

Comments
 (0)