diff --git a/app/guilds.tsx b/app/guilds.tsx
index 17c335e..1154ad4 100644
--- a/app/guilds.tsx
+++ b/app/guilds.tsx
@@ -15,8 +15,6 @@ export default function Guilds() {
const { walletAddress } = useWallet();
const { getMembership } = useMembership(walletAddress);
- // In a real app, you would fetch all guilds.
- // For MVP, we'll show a few example guilds that the user can explore.
const exampleGuilds = [
{ id: "guild_abc", name: "Alpha Guild", isActive: true, roleCount: 3 },
{ id: "guild_xyz", name: "Beta Community", isActive: true, roleCount: 5 },
diff --git a/app/settings.tsx b/app/settings.tsx
index ae1c48d..4c98615 100644
--- a/app/settings.tsx
+++ b/app/settings.tsx
@@ -25,52 +25,54 @@ export default function Settings() {
const chainId = appConfig.chainId;
return (
-
-
-
- Protocol Configuration
-
-
- API URL
-
- {apiUrl}
-
-
-
- Default Chain ID
-
- {chainId}
-
-
-
- SDK Version
-
- 0.1.0-mvp
-
-
-
+
+
+
+
+ Protocol Configuration
+
+
+ API URL
+
+ {apiUrl}
+
+
+
+ Default Chain ID
+
+ {chainId}
+
+
+
+ SDK Version
+
+ 0.1.0-mvp
+
+
+
- Account
-
-
-
- will disconnect your current wallet address and clear any local cache.
-
-
-
-
+ Account
+
+
+
+ will disconnect your current wallet address and clear any local cache.
+
+
+
+
-
- GuildPass Mobile MVP v1.0.0
- Built with Expo & NativeWind
-
-
-
+
+ GuildPass Mobile MVP v1.0.0
+ Built with Expo and NativeWind
+
+
+
+
);
}
diff --git a/src/components/WalletRequired.tsx b/src/components/WalletRequired.tsx
index b32355b..e09c585 100644
--- a/src/components/WalletRequired.tsx
+++ b/src/components/WalletRequired.tsx
@@ -6,17 +6,9 @@ import { Button } from "./Button";
interface WalletRequiredProps {
children: React.ReactNode;
- /**
- * When true (default), redirects to /profile if wallet is not connected.
- * When false, renders an inline connect-wallet prompt instead.
- */
redirect?: boolean;
}
-/**
- * Route guard that ensures a wallet is connected before rendering
- * wallet-scoped content. Redirects to /profile or shows a connect prompt.
- */
export function WalletRequired({
children,
redirect = true,
@@ -30,7 +22,6 @@ export function WalletRequired({
}
}, [isHydrated, isConnected, redirect, router]);
- // Wait for store hydration to avoid flash of wrong state
if (!isHydrated) {
return null;
}
diff --git a/tests/walletRequired.test.tsx b/tests/walletRequired.test.tsx
index 0895df7..5cb7752 100644
--- a/tests/walletRequired.test.tsx
+++ b/tests/walletRequired.test.tsx
@@ -43,14 +43,12 @@ describe("WalletRequired", () => {
);
});
-
expect(JSON.stringify(tree.toJSON())).toContain("Protected content");
});
it("returns null when store is not yet hydrated", () => {
mockIsConnected.mockReturnValue(false);
mockIsHydrated.mockReturnValue(false);
-
let tree: any;
act(() => {
tree = TestRenderer.create(
@@ -59,14 +57,12 @@ describe("WalletRequired", () => {
);
});
-
expect(tree.toJSON()).toBeNull();
});
it("redirects to /profile when disconnected and redirect=true", () => {
mockIsConnected.mockReturnValue(false);
mockIsHydrated.mockReturnValue(true);
-
act(() => {
TestRenderer.create(
@@ -74,14 +70,12 @@ describe("WalletRequired", () => {
);
});
-
expect(mockReplace).toHaveBeenCalledWith("/profile");
});
it("shows connect-wallet prompt when disconnected and redirect=false", () => {
mockIsConnected.mockReturnValue(false);
mockIsHydrated.mockReturnValue(true);
-
let renderer: any;
act(() => {
renderer = TestRenderer.create(
@@ -90,7 +84,6 @@ describe("WalletRequired", () => {
);
});
-
expect(renderer.root.findByProps({ testID: "wallet-required-prompt" })).toBeDefined();
expect(renderer.root.findByProps({ testID: "wallet-required-connect" })).toBeDefined();
expect(mockReplace).not.toHaveBeenCalled();