Skip to content

Commit

Permalink
fix function name
Browse files Browse the repository at this point in the history
  • Loading branch information
js-jankisalvi committed Jun 3, 2024
1 parent d298b5a commit 9c29363
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions x-pack/plugins/cases/public/components/templates/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const TemplatesComponent: React.FC<Props> = ({
const canAddTemplates = permissions.create && permissions.update;
const [error, setError] = useState<boolean>(false);

const onAddCustomField = useCallback(() => {
const onAddTemplate = useCallback(() => {
if (templates.length === MAX_TEMPLATES_LENGTH && !error) {
setError(true);
return;
Expand Down Expand Up @@ -92,7 +92,7 @@ const TemplatesComponent: React.FC<Props> = ({
isLoading={isLoading}
isDisabled={disabled || error}
size="s"
onClick={onAddCustomField}
onClick={onAddTemplate}
iconType="plusInCircle"
data-test-subj="add-template"
>
Expand Down

0 comments on commit 9c29363

Please sign in to comment.