Skip to content

Commit 5ce2e52

Browse files
committed
refactor(CModal): improve syntax
1 parent 8c6b693 commit 5ce2e52

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/modal/CModal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ export const CModal = forwardRef<HTMLDivElement, CModalProps>(
131131
document.body.classList.add('modal-open')
132132
setTimeout(
133133
() => {
134-
modalRef.current && modalRef.current.focus()
134+
modalRef.current?.focus()
135135
},
136136
!transition ? 0 : duration,
137137
)

0 commit comments

Comments
 (0)