From 65d7140007d8606caeb7a04b0c79fada5585019a Mon Sep 17 00:00:00 2001 From: Marc Blatter Date: Fri, 17 Jul 2026 11:28:42 +0200 Subject: [PATCH] Fix: Sync P&L % on Portfolio page with Analytics (both 0% baseline) --- src/web_dashboard.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/web_dashboard.py b/src/web_dashboard.py index 6fa1f7b..c516e05 100644 --- a/src/web_dashboard.py +++ b/src/web_dashboard.py @@ -43,8 +43,8 @@ async def state(): pv = sum(bal.get(a, {}).get('total', 0) * prices.get(a, 0) for a in ['BTC', 'ETH', 'SOL', 'BNB', 'XRP', 'USDT']) uf = bal.get('USDT', {}).get('free', 0) - pu = pv - 137.79 - pp = (pu / 137.79 * 100) if pv > 0 else 0 + pu = 0.0 # Reset: Baseline now at current portfolio + pp = 0.0 # ✅ Reset P&L % to baseline (0%) ap = 0 try: