Fakultas Ilmu Komputer UI

Commit 6e3f46d8 authored by FadhilP's avatar FadhilP
Browse files

[REFACTOR] Reallocate error

parent a84db37a
import React from "react";
import { css } from "@emotion/core";
import { ErrorDiv } from "../../component/html/html";
import FormBatch from "./FormBatch";
import useSendData from "../../utils/useSendData";
import { Link } from "@reach/router";
......@@ -31,10 +30,6 @@ const TambahBatch = () => {
flex-direction: column;
`}
>
<div>
{error && <ErrorDiv>Error !, Data tidak dapat disimpan</ErrorDiv>}
</div>
<div
css={css`
font-style: normal;
......@@ -62,7 +57,7 @@ const TambahBatch = () => {
>
Informasi Batch
</div>
<FormBatch {...{ onSubmit }} />
<FormBatch {...{ onSubmit, error }} />
</div>
);
};
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment