Skip to content

Commit

Permalink
Refactor .gitignore to exclude /src/app/(client)
Browse files Browse the repository at this point in the history
  • Loading branch information
gkhaavik committed Oct 16, 2024
1 parent a3b1b4f commit 4a6bc4d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
/.pnp
.pnp.js
.yarn/install-state.gz
/src/app/(client)

# testing
/coverage
Expand Down
4 changes: 2 additions & 2 deletions src/app/demo/checkout/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export default function Checkout() {

useEffect(() => {
if (cart.length === 0) {
router.push('/');
router.push('/demo');
}
if (user) {
setEmail(user.email);
Expand Down Expand Up @@ -64,7 +64,7 @@ export default function Checkout() {
setError(null);
try {
await createOrder(user.userId, cart).then((order) => {
router.push(`/checkout/success/${order.orderId}`);
router.push(`/demo/checkout/success/${order.orderId}`);
});

} catch (err) {
Expand Down
4 changes: 2 additions & 2 deletions src/app/demo/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export default function Home() {
}, []);

const handleCheckout = () => {
router.push('/checkout');
router.push('/demo/checkout');
};

return (
Expand All @@ -32,7 +32,7 @@ export default function Home() {
<span>Welcome, {user?.firstName}</span>
) : (
<button
onClick={() => router.push('/login')}
onClick={() => router.push('/demo/login')}
className="bg-blue-500 text-white px-4 py-2 rounded hover:bg-blue-600 transition-colors"
>
Login
Expand Down

0 comments on commit 4a6bc4d

Please sign in to comment.