Skip to content

Commit

Permalink
Merge pull request #10 from teakivy/master
Browse files Browse the repository at this point in the history
  • Loading branch information
Loudbooks authored Dec 8, 2024
2 parents cb32252 + e5c9fa2 commit 69425e5
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion frontend/src/components/Toolbar.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
<toolbar>
<button id="main" on:click={home}>{$title.toUpperCase()}</button>
<buttons>
<button on:click={settings}>SETTINGS</button>
{#if !$disableNew}
<button on:click={settings}>SETTINGS</button>
<button on:click={newPaste}>NEW</button>
{/if}
</buttons>
Expand Down
1 change: 0 additions & 1 deletion frontend/src/routes/new/+page.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { error } from "@sveltejs/kit";

export async function load() {
if (process.env.DISABLE_NEW?.toLowerCase() === "true") {
console.log("Disabled");
error(404, {
message: "Not Found",
});
Expand Down
9 changes: 9 additions & 0 deletions frontend/src/routes/settings/+page.server.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { error } from "@sveltejs/kit";

export async function load() {
if (process.env.DISABLE_NEW?.toLowerCase() === "true") {
error(404, {
message: "Not Found",
});
}
}

0 comments on commit 69425e5

Please sign in to comment.