mirror of
https://github.com/hydralauncher/hydra.git
synced 2025-02-02 16:23:48 +03:00
feat: use env
This commit is contained in:
parent
6d1f290895
commit
b7f717a6f4
@ -14,8 +14,12 @@ const openCheckout = async (_event: Electron.IpcMainInvokeEvent) => {
|
||||
refreshToken: userAuth.refreshToken,
|
||||
}).then((response) => response.accessToken);
|
||||
|
||||
const params = new URLSearchParams({
|
||||
token: paymentToken,
|
||||
});
|
||||
|
||||
shell.openExternal(
|
||||
"https://checkout.hydralauncher.gg/?token=" + paymentToken
|
||||
`${import.meta.env.MAIN_VITE_CHECKOUT_URL}?${params.toString()}`
|
||||
);
|
||||
};
|
||||
|
||||
|
1
src/main/vite-env.d.ts
vendored
1
src/main/vite-env.d.ts
vendored
@ -5,6 +5,7 @@ interface ImportMetaEnv {
|
||||
readonly MAIN_VITE_API_URL: string;
|
||||
readonly MAIN_VITE_AUTH_URL: string;
|
||||
readonly MAIN_VITE_SENTRY_DSN: string;
|
||||
readonly MAIN_VITE_CHECKOUT_URL: string;
|
||||
}
|
||||
|
||||
interface ImportMeta {
|
||||
|
Loading…
Reference in New Issue
Block a user