diff --git a/Oqtane.Shared/Models/Route.cs b/Oqtane.Shared/Models/Route.cs index 87577c02..a827e85d 100644 --- a/Oqtane.Shared/Models/Route.cs +++ b/Oqtane.Shared/Models/Route.cs @@ -66,9 +66,12 @@ namespace Oqtane.Models Action = ModuleId.Substring(pos + 1); Action = (!string.IsNullOrEmpty(Action)) ? Action : Constants.DefaultAction; ModuleId = ModuleId.Substring(0, pos); - ModuleId = (int.TryParse(ModuleId, out _)) ? ModuleId : "-1"; } } + if (!int.TryParse(ModuleId, out _)) + { + ModuleId = "-1"; + } if (PagePath.StartsWith("/")) { PagePath = (PagePath.Length == 1) ? "" : PagePath.Substring(1);