Skip to content

Commit bcfff01

Browse files
committed
⚰️ Remove unnecessary usage check
1 parent 7bb7386 commit bcfff01

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/components/commands/Email.tsx

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,19 @@
11
import { useContext } from "react";
22
import _ from "lodash";
3-
import { UsageDiv, Wrapper } from "../styles/Output.styled";
3+
import { Wrapper } from "../styles/Output.styled";
44
import { termContext } from "../Terminal";
55

66
const Email: React.FC = () => {
7-
const { arg, history, rerender } = useContext(termContext);
7+
const { history, rerender } = useContext(termContext);
88

99
/* ===== get current command ===== */
1010
const currentCommand = _.split(history[0], " ");
1111

1212
if (rerender && currentCommand[0] === "email" && currentCommand.length <= 1) {
13-
// location.href = "mailto:" + "[email protected]";
1413
window.open("mailto:" + "[email protected]", "_self");
1514
}
1615

17-
return arg.length > 0 ? (
18-
<UsageDiv>Usage: email</UsageDiv>
19-
) : (
16+
return (
2017
<Wrapper>
2118
<span>[email protected]</span>
2219
</Wrapper>

0 commit comments

Comments
 (0)