IPC and Linux check-ups fixes

This commit is contained in:
Oleh Polisan 2025-02-11 17:55:16 +02:00
parent f82c1a4d4e
commit 9c9b577f52
4 changed files with 6 additions and 5 deletions

View file

@ -77,3 +77,4 @@ export const enum MessageBoxChoice {
export const isWayland = export const isWayland =
process.platform === "linux" && (process.env.XDG_SESSION_TYPE === "wayland" || !!process.env.WAYLAND_DISPLAY); process.platform === "linux" && (process.env.XDG_SESSION_TYPE === "wayland" || !!process.env.WAYLAND_DISPLAY);
export const isLinux = process.platform === "linux";

View file

@ -66,9 +66,7 @@ function openFIFO() {
function cleanup() { function cleanup() {
try { try {
unlinkSync(socketFile); unlinkSync(socketFile);
} catch (err) { } catch (err) {}
console.error("Failed to remove mkfifo file:", err);
}
} }
process.on("exit", cleanup); process.on("exit", cleanup);

View file

@ -31,7 +31,7 @@ import {
DATA_DIR, DATA_DIR,
DEFAULT_HEIGHT, DEFAULT_HEIGHT,
DEFAULT_WIDTH, DEFAULT_WIDTH,
isWayland, isLinux,
MessageBoxChoice, MessageBoxChoice,
MIN_HEIGHT, MIN_HEIGHT,
MIN_WIDTH, MIN_WIDTH,
@ -537,5 +537,5 @@ export async function createWindows() {
}); });
initArRPC(); initArRPC();
if (isWayland) initKeybinds(); if (isLinux) initKeybinds();
} }

View file

@ -13,6 +13,8 @@ import "./arrpc";
export * as Components from "./components"; export * as Components from "./components";
import { findByPropsLazy } from "@vencord/types/webpack";
import SettingsUi from "./components/settings/Settings"; import SettingsUi from "./components/settings/Settings";
import { VesktopLogger } from "./logger"; import { VesktopLogger } from "./logger";
import { Settings } from "./settings"; import { Settings } from "./settings";