Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/deploy-testnet.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Deploy Contracts to Testnet

on:
push:
branches:
- main
workflow_dispatch:
inputs:
force:
Expand Down
1 change: 1 addition & 0 deletions apps/api/src/pools/pools.repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ export class PoolsRepository {
where: search
? {
OR: [
{ id: { contains: search, mode: 'insensitive' } },
{ token0Address: { contains: search, mode: 'insensitive' } },
{ token1Address: { contains: search, mode: 'insensitive' } },
],
Expand Down
12 changes: 6 additions & 6 deletions apps/web/app/portfolio/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { useEffect } from 'react';
import { useWalletContext } from '@/context/WalletContext';
import { usePortfolio } from '@/hooks/usePortfolio';
import { PositionCard } from '@/components/PositionCard';
import { WalletButton } from '@/components/WalletButton';
import { API_BASE, SWYFT_NETWORK_PASSPHRASE } from '@/lib/constants';
import { signTransaction } from '@stellar/freighter-api';
import { buildCollectTx } from '@swyft/sdk';
Expand All @@ -24,12 +25,6 @@ export default function PortfolioPage() {
const [showClosed, setShowClosed] = useState(false);
const [collectingId, setCollectingId] = useState<string | null>(null);

// Redirect if no wallet connected
useEffect(() => {
if (address === null && !loading) {
router.replace('/');
}
}, [address, loading, router]);

const handleCollectFees = useCallback(
async (positionId: string) => {
Expand Down Expand Up @@ -143,6 +138,11 @@ export default function PortfolioPage() {
{/* Empty state */}
{!loading && positions.length === 0 && (
<div className="flex flex-col items-center justify-center gap-4 py-20 text-center">
{!address && (
<div className="mb-4">
<WalletButton />
</div>
)}
{showClosed ? (
<>
<p className="text-sm text-zinc-500">You have no positions yet.</p>
Expand Down
2 changes: 1 addition & 1 deletion packages/contract/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"deploy:testnet:force": "bash scripts/deploy-testnet.sh --force"
},
"devDependencies": {
"@stellar/stellar-sdk": "^13.0.0",
"@stellar/stellar-sdk": "^13.1.0",
"@types/jest": "^30.0.0",
"jest": "^30.0.0",
"ts-jest": "^29.2.5",
Expand Down