Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Le formatting
  • Loading branch information
regalijan committed Oct 19, 2023
1 parent b5a92db commit 486762c
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions components/NewInfractionModal.tsx
Expand Up @@ -10,11 +10,11 @@ import {
ModalOverlay,
Select,
Text,
useToast
useToast,
} from "@chakra-ui/react";
import { useState } from "react";

export default function(props: { isOpen: boolean; onClose: () => void }) {
export default function (props: { isOpen: boolean; onClose: () => void }) {
const [loading, setLoading] = useState(false);
const [punishment, setPunishment] = useState("");
const [user, setUser] = useState("");
Expand All @@ -24,7 +24,7 @@ export default function(props: { isOpen: boolean; onClose: () => void }) {
if (!props.isOpen) return;

const evidenceElement = document.getElementById(
"evidence"
"evidence",
) as HTMLInputElement;

if (!evidenceElement.files && e.clipboardData?.files) {
Expand Down Expand Up @@ -74,7 +74,7 @@ export default function(props: { isOpen: boolean; onClose: () => void }) {

const postReq = await fetch("/api/infractions/new", {
body: form,
method: "POST"
method: "POST",
});

if (postReq.ok) {
Expand All @@ -84,7 +84,7 @@ export default function(props: { isOpen: boolean; onClose: () => void }) {
duration: 5000,
isClosable: true,
status: "success",
title: "Success"
title: "Success",
});

props.onClose();
Expand All @@ -100,7 +100,7 @@ export default function(props: { isOpen: boolean; onClose: () => void }) {
duration: 5000,
isClosable: true,
status: "error",
title: "Error"
title: "Error",
});
}

Expand Down

0 comments on commit 486762c

Please sign in to comment.