Skip to content

Commit

Permalink
Merge pull request #118 from bmf-san/feature/add-ads-txt
Browse files Browse the repository at this point in the history
ads.txtを追加
  • Loading branch information
bmf-san authored Oct 8, 2024
2 parents 2563e92 + d1b2f1e commit 636048f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,10 @@ func main() {
http.FileServer(http.Dir("static")).ServeHTTP(w, r)
}))

r.Methods(http.MethodGet).Use(mw.Log, mw.Recovery).Handler(`/ads.txt`, http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
http.FileServer(http.Dir("static")).ServeHTTP(w, r)
}))

r.Methods(http.MethodGet).Use(mw.Log, mw.Recovery).Handler(`/profile.png`, http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
http.FileServer(http.Dir("static")).ServeHTTP(w, r)
}))
Expand Down
1 change: 1 addition & 0 deletions app/static/ads.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
google.com, pub-5146230866088201, DIRECT, f08c47fec0942fa0

0 comments on commit 636048f

Please sign in to comment.