aboutsummaryrefslogtreecommitdiff
path: root/client.go
diff options
context:
space:
mode:
Diffstat (limited to 'client.go')
-rw-r--r--client.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/client.go b/client.go
index bef5c77..31e11f2 100644
--- a/client.go
+++ b/client.go
@@ -123,6 +123,8 @@ func IndexGet(w http.ResponseWriter, r *http.Request, db *sql.DB) {
data.InstanceIndex = GetCollectionFromReq("https://fchan.xyz/followers").Items
data.NewsItems = getNewsFromDB(db, 3)
+ data.Themes = &Themes
+
t.ExecuteTemplate(w, "layout", data)
}
@@ -156,6 +158,8 @@ func NewsGet(w http.ResponseWriter, r *http.Request, db *sql.DB, timestamp int)
data.Title = actor.PreferredUsername + ": " + data.NewsItems[0].Title
+ data.Themes = &Themes
+
t.ExecuteTemplate(w, "layout", data)
}
@@ -180,6 +184,8 @@ func AllNewsGet(w http.ResponseWriter, r *http.Request, db *sql.DB) {
data.Board.Restricted = actor.Restricted
data.NewsItems = getNewsFromDB(db, 0)
+ data.Themes = &Themes
+
t.ExecuteTemplate(w, "layout", data)
}
@@ -329,6 +335,8 @@ func CatalogGet(w http.ResponseWriter, r *http.Request, db *sql.DB, collection C
returnData.Posts = collection.OrderedItems
+ returnData.Themes = &Themes
+
t.ExecuteTemplate(w, "layout", returnData)
}