Compare commits
2 Commits
abc11e112f
...
ecc12333e1
Author | SHA1 | Date |
---|---|---|
Niko Abeler | ecc12333e1 | |
Niko Abeler | 33ca1fba6f |
|
@ -8,6 +8,7 @@ import (
|
||||||
"os"
|
"os"
|
||||||
"path"
|
"path"
|
||||||
"strings"
|
"strings"
|
||||||
|
"time"
|
||||||
|
|
||||||
"github.com/julienschmidt/httprouter"
|
"github.com/julienschmidt/httprouter"
|
||||||
)
|
)
|
||||||
|
@ -288,7 +289,7 @@ func userMicropubHandler(repo *owl.Repository) func(http.ResponseWriter, *http.R
|
||||||
|
|
||||||
if h != "entry" {
|
if h != "entry" {
|
||||||
w.WriteHeader(http.StatusBadRequest)
|
w.WriteHeader(http.StatusBadRequest)
|
||||||
w.Write([]byte("Bad request. h must be entry"))
|
w.Write([]byte("Bad request. h must be entry. Got " + h))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if content == "" {
|
if content == "" {
|
||||||
|
@ -304,6 +305,7 @@ func userMicropubHandler(repo *owl.Repository) func(http.ResponseWriter, *http.R
|
||||||
Reply: owl.Reply{
|
Reply: owl.Reply{
|
||||||
Url: inReplyTo,
|
Url: inReplyTo,
|
||||||
},
|
},
|
||||||
|
Date: time.Now(),
|
||||||
},
|
},
|
||||||
content,
|
content,
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue