From c2c53cedd28b288538ce3979ea2aa54bffd02b25 Mon Sep 17 00:00:00 2001 From: Lynnesbian Date: Fri, 4 Sep 2020 21:31:09 +1000 Subject: [PATCH] stript #anchors from urls --- BuypeebApp.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/BuypeebApp.cs b/BuypeebApp.cs index 438cc70..cfa38f6 100644 --- a/BuypeebApp.cs +++ b/BuypeebApp.cs @@ -20,7 +20,7 @@ namespace Buypeeb { public static string IDFromURL(string url) { // TODO: handle invalid URLs better, or at all really - Regex rx = new Regex(@"^([^?]+)"); + Regex rx = new Regex(@"^([^?#]+)"); url = rx.Match(url).Groups[1].Value; // remove query params (if any) rx = new Regex(@".+\/(.+?)/?$");