private static string EnsureResourceInfo(string path, ResourceType type, string name) { if (path == (string)RavenConfiguration.GetDefaultValue(x => x.Core.DataDirectory)) { if (type == ResourceType.Server) { return($"~{Path.DirectorySeparatorChar}"); } return(Path.Combine("~", $"{type}s", name)); } if (type == ResourceType.Server) { return(path); } return(Path.Combine(path, $"{type}s", name)); }