Skip to content

Commit

Permalink
remove dashboard layout and split into seperate routes
Browse files Browse the repository at this point in the history
  • Loading branch information
scottquested committed Jan 26, 2024
1 parent 67035e1 commit 76c9ea6
Show file tree
Hide file tree
Showing 23 changed files with 1,118 additions and 391 deletions.
4 changes: 2 additions & 2 deletions convex/mutations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export const saveJobs = mutation({
handler: async (ctx, { skills, userId }) => {
const identity = await ctx.auth.getUserIdentity();
if (!identity) {
return;
throw new Error("Not authenticated");
}

const jobs = await ctx.db.insert("jobs", {
Expand All @@ -33,7 +33,7 @@ export const retryJob = mutation({
handler: async (ctx, { id, skills }) => {
const identity = await ctx.auth.getUserIdentity();
if (!identity) {
return;
throw new Error("Not authenticated");
}

await ctx.db.patch(id, {
Expand Down
3 changes: 2 additions & 1 deletion convex/queries.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { query } from "./_generated/server";

export const getJobs = query({
args: {},
handler: async (ctx) => {
const identity = await ctx.auth.getUserIdentity();
if (!identity) {
return;
return [];
}

const jobs = await ctx.db
Expand Down
Loading

0 comments on commit 76c9ea6

Please sign in to comment.