fix: expired link

This commit is contained in:
kieran 2024-11-27 14:39:57 +00:00
parent e4f6863e21
commit 12c3ddc31d
No known key found for this signature in database
GPG Key ID: DE71CEB3925BE941
4 changed files with 6 additions and 5 deletions

1
.env Normal file
View File

@ -0,0 +1 @@
VITE_API_URL="https://api.lnvps.net"

1
.env.development Normal file
View File

@ -0,0 +1 @@
VITE_API_URL="http://localhost:8000"

View File

@ -26,7 +26,7 @@ export default function VpsInstanceRow({ vm, actions }: { vm: VmInstance, action
</div>
<VpsResources vm={vm} />
</div>
{(actions ?? true) && <div className="flex gap-2 items-center">
<div className="flex gap-2 items-center">
{isExpired && (
<>
<Link to="/vm/renew" className="text-red-500 text-sm" state={vm}>
@ -34,8 +34,8 @@ export default function VpsInstanceRow({ vm, actions }: { vm: VmInstance, action
</Link>
</>
)}
{!isExpired && <VmActions vm={vm} />}
</div>}
{!isExpired && (actions ?? true) && <VmActions vm={vm} />}
</div>
</div>
);
}

View File

@ -12,8 +12,7 @@ export const GB = KB * 1000;
export const TB = GB * 1000;
export const PB = TB * 1000;
//export const ApiUrl = "http://localhost:8000";
export const ApiUrl = "https://api.lnvps.net";
export const ApiUrl = import.meta.env.VITE_API_URL;
export const NostrProfile = new NostrLink(
NostrPrefix.Profile,