fix: derive currentUrl from actual page path

This commit is contained in:
httpjamesm 2024-03-09 11:27:37 -05:00
parent 42ad68fe34
commit a232a33b72
No known key found for this signature in database

View file

@ -109,7 +109,7 @@ func ViewQuestion(c *gin.Context) {
"answers": answers,
"imagePolicy": imagePolicy,
"theme": c.MustGet("theme").(string),
"currentUrl": fmt.Sprintf("%s/questions/%s/%s", os.Getenv("APP_URL"), questionId, params.QuestionTitle),
"currentUrl": fmt.Sprintf("%s%s", os.Getenv("APP_URL"), c.Request.URL.Path),
"sortValue": params.SoSortValue,
"domain": domain,
})