Send the epub moderating files

This commit is contained in:
Las Zenow 2012-08-25 16:41:54 +02:00
parent 7a3f47bb97
commit efbd3b3c09

View file

@ -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)