Rename getLandingPage -> getLandingBody

This makes the naming scheme more consistent with other funcs.

Ref T565
pull/131/head
Matt Baer 5 years ago
parent a72ce2ef29
commit c3f3eb0a65
  1. 2
      admin.go
  2. 2
      app.go
  3. 2
      pages.go

@ -317,7 +317,7 @@ func handleViewAdminPage(app *App, u *User, w http.ResponseWriter, r *http.Reque
if err != nil {
return impart.HTTPError{http.StatusInternalServerError, fmt.Sprintf("Could not get banner: %v", err)}
}
p.Content, err = getLandingPage(app)
p.Content, err = getLandingBody(app)
p.Content.ID = "landing"
} else {
p.Content, err = app.db.GetDynamicContent(slug)

@ -219,7 +219,7 @@ func handleViewHome(app *App, w http.ResponseWriter, r *http.Request) error {
}
p.Banner = template.HTML(applyMarkdown([]byte(banner.Content), ""))
content, err := getLandingPage(app)
content, err := getLandingBody(app)
if err != nil {
log.Error("unable to get landing content: %v", err)
return impart.HTTPError{http.StatusInternalServerError, fmt.Sprintf("Could not get content: %v", err)}

@ -96,7 +96,7 @@ func getLandingBanner(app *App) (*instanceContent, error) {
return c, nil
}
func getLandingPage(app *App) (*instanceContent, error) {
func getLandingBody(app *App) (*instanceContent, error) {
c, err := app.db.GetDynamicContent("landing-body")
if err != nil {
return nil, err

Loading…
Cancel
Save