mirror of
https://github.com/writeas/writefreely
synced 2025-02-06 20:03:24 +01:00
Rename getLandingPage -> getLandingBody
This makes the naming scheme more consistent with other funcs. Ref T565
This commit is contained in:
parent
a72ce2ef29
commit
c3f3eb0a65
2
admin.go
2
admin.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)
|
||||
|
2
app.go
2
app.go
@ -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)}
|
||||
|
2
pages.go
2
pages.go
@ -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…
x
Reference in New Issue
Block a user