Skip to content

Commit 33787e0

Browse files
Fix url router for absolute URLs (#270)
Co-authored-by: claudia <cmurialdo@gmail.com>
1 parent f0d49fb commit 33787e0

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

dotnet/src/dotnetframework/GxClasses/Model/URLRouter.cs

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,16 @@ internal static string GetURLRoute(string key, object[] objectParms, string[] pa
2121
{
2222
string[] parms = objectParms.Select(p => StringizeParm(p)).ToArray() ;
2323
if (PathUtil.IsAbsoluteUrl(key) || key.StartsWith("/") || scheme.IsMatch(key))
24-
return key;
24+
{
25+
if (parms.Length > 0)
26+
{
27+
return $"{key}{ConvertParmsToQueryString(parms, parmsName)}";
28+
}
29+
else
30+
{
31+
return key;
32+
}
33+
}
2534

2635
if (routerList == null)
2736
{

0 commit comments

Comments
 (0)