From 3b298bf3fb46a73e52af01cc5203df7fa22b36cd Mon Sep 17 00:00:00 2001 From: Amy Gale Ruth Bowersox Date: Sat, 11 Apr 2026 22:46:15 -0600 Subject: [PATCH] Fixed bug in post link resolution that was causing conference alias to be set wrongg on post links. Closes issue #3. --- conference.go | 8 ++++---- docs/CHANGELOG.md | 5 +++++ 2 files changed, 9 insertions(+), 4 deletions(-) create mode 100644 docs/CHANGELOG.md diff --git a/conference.go b/conference.go index e2452a0..f84b4d6 100644 --- a/conference.go +++ b/conference.go @@ -247,7 +247,7 @@ func NewTopic(ctxt ui.AmContext) (string, any) { if err != nil { return "error", err } - checker.SetContext("PostLinkDecoderContext", database.AmCreatePostLinkContext(comm.Alias, ctxt.URLParam("cid"), conf.TopTopic+1)) + checker.SetContext("PostLinkDecoderContext", database.AmCreatePostLinkContext(comm.Alias, ctxt.GetScratch("currentAlias").(string), conf.TopTopic+1)) checker.Append(postdata) checker.Finish() v, _ = checker.Value() @@ -282,7 +282,7 @@ func NewTopic(ctxt ui.AmContext) (string, any) { if err != nil { return "error", err } - checker.SetContext("PostLinkDecoderContext", database.AmCreatePostLinkContext(comm.Alias, ctxt.URLParam("cid"), conf.TopTopic+1)) + checker.SetContext("PostLinkDecoderContext", database.AmCreatePostLinkContext(comm.Alias, ctxt.GetScratch("currentAlias").(string), conf.TopTopic+1)) checker.Append(ctxt.FormField("pb")) checker.Finish() zeroPost, _ := checker.Value() @@ -734,7 +734,7 @@ func PostInTopic(ctxt ui.AmContext) (string, any) { if err != nil { return "error", err } - checker.SetContext("PostLinkDecoderContext", database.AmCreatePostLinkContext(comm.Alias, ctxt.URLParam("cid"), topic.Number)) + checker.SetContext("PostLinkDecoderContext", database.AmCreatePostLinkContext(comm.Alias, ctxt.GetScratch("currentAlias").(string), topic.Number)) checker.Append(postdata) checker.Finish() v, _ = checker.Value() @@ -805,7 +805,7 @@ func PostInTopic(ctxt ui.AmContext) (string, any) { if err != nil { return "error", err } - checker.SetContext("PostLinkDecoderContext", database.AmCreatePostLinkContext(comm.Alias, ctxt.URLParam("cid"), topic.Number)) + checker.SetContext("PostLinkDecoderContext", database.AmCreatePostLinkContext(comm.Alias, ctxt.GetScratch("currentAlias").(string), topic.Number)) checker.Append(ctxt.FormField("pb")) checker.Finish() postText, _ := checker.Value() diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md new file mode 100644 index 0000000..01b251a --- /dev/null +++ b/docs/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## Release 0.1.0 - April 6, 2026 + +* Implemented all functionality from the last known version of the Venice Web Communities System, circa 2006.