Send the epub moderating files
This commit is contained in:
parent
7a3f47bb97
commit
efbd3b3c09
1 changed files with 5 additions and 0 deletions
5
admin.go
5
admin.go
|
@ -117,6 +117,11 @@ type newData struct {
|
|||
|
||||
func newHandler(coll *mgo.Collection) func(http.ResponseWriter, *http.Request) {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
if len(r.URL.Path) > len("/new/") {
|
||||
http.ServeFile(w, r, r.URL.Path[1:])
|
||||
return
|
||||
}
|
||||
|
||||
sess := GetSession(r)
|
||||
if sess.User == "" {
|
||||
http.NotFound(w, r)
|
||||
|
|
Reference in a new issue