Fix unused code
This commit is contained in:
parent
8d1890162c
commit
f19e0288a3
2 changed files with 1 additions and 19 deletions
|
@ -2,7 +2,6 @@ import { WindowTitle } from "@saleor/components/WindowTitle";
|
|||
import useNavigator from "@saleor/hooks/useNavigator";
|
||||
import useNotifier from "@saleor/hooks/useNotifier";
|
||||
import { commonMessages } from "@saleor/intl";
|
||||
import { WebhookEventTypeEnum } from "@saleor/types/globalTypes";
|
||||
import { WebhookCreate as WebhookCreateData } from "@saleor/webhooks/types/WebhookCreate";
|
||||
import React from "react";
|
||||
import { useIntl } from "react-intl";
|
||||
|
@ -47,7 +46,7 @@ export const WebhooksCreate: React.StatelessComponent<
|
|||
WebhookCreate({
|
||||
variables: {
|
||||
input: {
|
||||
events: [WebhookEventTypeEnum.ORDER_CREATED],
|
||||
events: data.events,
|
||||
isActive: data.isActive,
|
||||
name: data.name,
|
||||
secretKey: data.secretKey,
|
||||
|
|
|
@ -83,23 +83,6 @@ export const WebhooksDetails: React.StatelessComponent<
|
|||
[]
|
||||
);
|
||||
|
||||
if (formErrors.length) {
|
||||
formErrors.map(error => {
|
||||
notify({
|
||||
text: error.message
|
||||
});
|
||||
});
|
||||
} else {
|
||||
if (webhookUpdateOpts.data) {
|
||||
notify({
|
||||
text: intl.formatMessage({
|
||||
defaultMessage: "Succesfully updated plugin settings",
|
||||
description: "plugin success message"
|
||||
})
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
const deleteTransitionState = getMutationState(
|
||||
webhookDeleteOpts.called,
|
||||
webhookDeleteOpts.loading,
|
||||
|
|
Loading…
Reference in a new issue