fixx meshcentral url
This commit is contained in:
parent
bd21d18c21
commit
2cdeed2165
|
|
@ -8,7 +8,6 @@ import { useGetClientFolderStatusForDevice } from "@/hooks/queries";
|
|||
import type { ClientFolderStatus } from "@/types/folder";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { getRemoteDesktopUrl } from "@/services/remote-control.service";
|
||||
import { buildMeshProxyUrl } from "@/config/api";
|
||||
import { toast } from "sonner";
|
||||
export function ComputerCard({
|
||||
device,
|
||||
|
|
@ -58,11 +57,7 @@ export function ComputerCard({
|
|||
try {
|
||||
setIsConnecting(true);
|
||||
const response = await getRemoteDesktopUrl(device.id);
|
||||
const originalUrl = new URL(response.url);
|
||||
const pathAndQuery = originalUrl.pathname + originalUrl.search;
|
||||
const proxyUrlFull = buildMeshProxyUrl(pathAndQuery);
|
||||
|
||||
setProxyUrl(proxyUrlFull);
|
||||
setProxyUrl(response.url);
|
||||
setShowRemote(true);
|
||||
} catch (error: any) {
|
||||
toast.error(
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user