Add newsletter redirect link

This commit is contained in:
Ben Visness 2023-06-02 09:46:26 -05:00
parent 57782aba5f
commit dd6e5e3b66
2 changed files with 10 additions and 0 deletions

View File

@ -49,6 +49,13 @@ func BuildWhenIsIt() string {
return Url("/whenisit", nil) return Url("/whenisit", nil)
} }
var RegexNewsletterSignup = regexp.MustCompile("^/newsletter$")
func BuildNewsletterSignup() string {
defer CatchPanic()
return Url("/newsletter", nil)
}
var RegexJamsIndex = regexp.MustCompile("^/jams$") var RegexJamsIndex = regexp.MustCompile("^/jams$")
func BuildJamsIndex() string { func BuildJamsIndex() string {

View File

@ -55,6 +55,9 @@ func NewWebsiteRoutes(conn *pgxpool.Pool) http.Handler {
hmnOnly.GET(hmnurl.RegexProjectSubmissionGuidelines, ProjectSubmissionGuidelines) hmnOnly.GET(hmnurl.RegexProjectSubmissionGuidelines, ProjectSubmissionGuidelines)
hmnOnly.GET(hmnurl.RegexConferences, Conferences) hmnOnly.GET(hmnurl.RegexConferences, Conferences)
hmnOnly.GET(hmnurl.RegexWhenIsIt, WhenIsIt) hmnOnly.GET(hmnurl.RegexWhenIsIt, WhenIsIt)
hmnOnly.GET(hmnurl.RegexNewsletterSignup, func(c *RequestContext) ResponseData {
return c.Redirect("https://cdn.forms-content.sg-form.com/9c83182a-f04a-11ed-a42d-f6f307313b7c", http.StatusFound)
})
hmnOnly.GET(hmnurl.RegexJamsIndex, JamsIndex) hmnOnly.GET(hmnurl.RegexJamsIndex, JamsIndex)
hmnOnly.GET(hmnurl.RegexJamIndex, func(c *RequestContext) ResponseData { hmnOnly.GET(hmnurl.RegexJamIndex, func(c *RequestContext) ResponseData {