aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'main.go')
-rw-r--r--main.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/main.go b/main.go
index bd88c41..35b9fe3 100644
--- a/main.go
+++ b/main.go
@@ -33,7 +33,6 @@ var SiteEmailPassword = GetConfigValue("emailpass")
var SiteEmailServer = GetConfigValue("emailserver") //mail.fchan.xyz
var SiteEmailPort = GetConfigValue("emailport") //587
-var ldjson = "application/ld+json"
var activitystreams = "application/ld+json; profile=\"https://www.w3.org/ns/activitystreams\""
func main() {
@@ -137,7 +136,7 @@ func main() {
}
if mainActor {
- if accept == activitystreams || accept == ldjson {
+ if acceptActivity(accept) {
GetActorInfo(w, db, Domain)
return
}
@@ -180,7 +179,7 @@ func main() {
}
if actorMain || actorMainPage {
- if accept == activitystreams || accept == ldjson {
+ if acceptActivity(accept) {
GetActorInfo(w, db, actor.Id)
return
}
@@ -267,7 +266,7 @@ func main() {
//catch all
if actorPost {
- if accept == activitystreams || accept == ldjson {
+ if acceptActivity(accept) {
GetActorPost(w, db, path)
return
}