Skip to content

Commit

Permalink
Update _index.jsx
Browse files Browse the repository at this point in the history
  • Loading branch information
mattsrobot committed Jan 7, 2024
1 parent e04e653 commit fb3d5f3
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions app/routes/_index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Flex, Card, Heading, Text, Button, Dialog, TextField, Strong, Link } fr
import { authorize } from "../sessions.server.js";
import { json, redirect } from "@remix-run/node";
import CreateCommunityDialog from '../components/create-community-dialog.jsx';
import { me, createCommunity } from "../wikid.server.js";
import { createCommunity } from "../wikid.server.js";
import { useLoaderData } from "@remix-run/react";
import { MagnifyingGlassIcon } from '@radix-ui/react-icons';

Expand All @@ -28,8 +28,7 @@ export const loader = async ({ request }) => {
const jwt = await authorize(request);

if (!!jwt) {
const [data, errors] = await me(jwt);
return json({ me: data, errors: errors });
return redirect('/c/get-started');
}

return json({ me: null, errors: null })
Expand Down

0 comments on commit fb3d5f3

Please sign in to comment.