Skip to content

Commit

Permalink
🚨 fix linting
Browse files Browse the repository at this point in the history
  • Loading branch information
nrmnqdds committed Oct 5, 2024
1 parent 5b1adfb commit 0f47a7f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 10 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ jobs:
version: latest

- name: Import Sorting
run: biome check --apply-unsafe .
run: biome check --write --unsafe .

- name: Format Code
run: biome format --write .
run: biome format --write --unsafe .

- name: Lint Code
run: biome lint .
Expand Down
6 changes: 1 addition & 5 deletions components/sections/FeatureSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,16 +89,12 @@ const Feature = () => {
</div>
</div>
<ContainerScroll
titleComponent={
<>
<h1 className="text-4xl font-semibold text-cyan-600">
titleComponent=<h1 className="text-4xl font-semibold text-cyan-600">
Everything you need <br />
<span className="text-4xl md:text-[6rem] font-bold mt-1 leading-none text-foreground">
i-Ma&apos;luum on steroid!
</span>
</h1>
</>
}
/>
</div>
<div className="mx-auto mt-16 max-w-7xl px-6 sm:mt-20 md:mt-0 lg:px-8">
Expand Down
8 changes: 5 additions & 3 deletions lib/server/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,17 +48,19 @@ export async function ImaluumLogin(form: {
followRedirect: false,
});

const cookieStore = cookieJar.toJSON().cookies;
const cookieStore = cookieJar.toJSON()?.cookies;

if (cookieStore.length === 0) {
if (cookieStore?.length === 0) {
throw new Error("Invalid credentials!");
}

for (const cookie of cookieStore) {
// biome-ignore lint/style/noNonNullAssertion: <explanation>
for (const cookie of cookieStore!) {
// console.log(cookie);
if (cookie.key === "MOD_AUTH_CAS") {
cookies().set({
name: "MOD_AUTH_CAS",
// biome-ignore lint/style/noNonNullAssertion: <explanation>
value: cookie.value!,
expires: new Date(Date.now() + 600000), // 10 minutes
});
Expand Down

0 comments on commit 0f47a7f

Please sign in to comment.