public static string GetUrlByRepositoryPath(string repositoryPath) { foreach (string key in _urlPaths.AllKeys) { if (string.Concat(repositoryPath, "/").StartsWith(string.Concat(_urlPaths[key], "/"))) { return key + repositoryPath.Substring(_urlPaths[key].Length); } } return null; }