From 7475ed7e32d88feeed078243197a44c0f95540fd Mon Sep 17 00:00:00 2001 From: Regalia <126194895+regalialong@users.noreply.github.com> Date: Mon, 13 Jan 2025 11:59:43 +0000 Subject: [PATCH] fix: Bad path combining causing custom resources not to load (#1077) Co-authored-by: Nekromateion <43814053+Nekromateion@users.noreply.github.com> --- Dotnet/AppApi/Cef/AppApiVr.cs | 3 ++- Dotnet/AppApi/Common/AppApiCommon.cs | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Dotnet/AppApi/Cef/AppApiVr.cs b/Dotnet/AppApi/Cef/AppApiVr.cs index d2385fb0..31fe5d21 100644 --- a/Dotnet/AppApi/Cef/AppApiVr.cs +++ b/Dotnet/AppApi/Cef/AppApiVr.cs @@ -75,7 +75,8 @@ namespace VRCX public string CustomVrScriptPath() { var output = string.Empty; - var filePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "VRCX\\customvr.js"); + var filePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "VRCX", + "customvr.js"); if (File.Exists(filePath)) output = filePath; return output; diff --git a/Dotnet/AppApi/Common/AppApiCommon.cs b/Dotnet/AppApi/Common/AppApiCommon.cs index f70e6f95..d789b0db 100644 --- a/Dotnet/AppApi/Common/AppApiCommon.cs +++ b/Dotnet/AppApi/Common/AppApiCommon.cs @@ -83,7 +83,8 @@ namespace VRCX public string CustomCssPath() { var output = string.Empty; - var filePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "VRCX\\custom.css"); + var filePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "VRCX", + "custom.css"); if (File.Exists(filePath)) output = filePath; return output; @@ -92,7 +93,8 @@ namespace VRCX public string CustomScriptPath() { var output = string.Empty; - var filePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "VRCX\\custom.js"); + var filePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "VRCX", + "custom.js"); if (File.Exists(filePath)) output = filePath; return output;