Skip to content

Commit f893bcd

Browse files
committed
chore: revert the check around event
1 parent 1cf077d commit f893bcd

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/Pages/GlobalConfigurations/Authorization/APITokens/GenerateModal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ const GenerateModal = ({
4343
redirectToTokenList()
4444
}
4545

46-
const handleCopyToClipboard = async (e?: React.MouseEvent) => {
46+
const handleCopyToClipboard = async (e: React.MouseEvent) => {
4747
stopPropagation(e)
4848
setCopyToClipboardPromise(copyToClipboard(token))
4949
}

src/components/ciPipeline/Webhook/WebhookDetailsModal.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -359,9 +359,7 @@ export const WebhookDetailsModal = ({ close, isTemplateView }: WebhookDetailType
359359
}
360360

361361
const handleCopyToClipboard = async ({ e, token }: { e: React.MouseEvent; token: string }) => {
362-
if (e) {
363-
stopPropagation(e)
364-
}
362+
stopPropagation(e)
365363
setCopyToClipboardPromise(copyToClipboard(token))
366364
}
367365

0 commit comments

Comments
 (0)