Compare commits

..

No commits in common. "61e4a848488abe834ae651ebe0ca9a5fd5a131f2" and "681d9e38bcdb33091e7c2a54b90cfb687fbe637e" have entirely different histories.

3 changed files with 2 additions and 4 deletions

View File

@ -4,7 +4,7 @@ RUN apk --no-cache add git
RUN go get p83.nl/go/ekster/cmd/ek
# final stage
FROM alpine:3.7
FROM alpine
RUN apk --no-cache add ca-certificates
RUN ["mkdir", "-p", "/opt/micropub"]
WORKDIR /opt/micropub

View File

@ -152,12 +152,10 @@ func loadSession(sessionVar string, conn redis.Conn) (session, error) {
if err != nil {
return sess, err
}
err = redis.ScanStruct(data, &sess)
if err != nil {
return sess, err
}
return sess, nil
}

View File

@ -33,6 +33,7 @@ type indexItem struct {
}
func addToSearch(item microsub.Item, channel string) error {
// TODO: add channel when indexing
if index != nil {
indexItem := indexItem{item, channel}
err := index.Index(item.ID, indexItem)
@ -89,7 +90,6 @@ func querySearch(channel, query string) ([]microsub.Item, error) {
web_1 | (string) (len=16) "author.longitude": (string) "",
*/
// TODO: fetch results from the channel instead of the search result
hits := res.Hits
for _, hit := range hits {
fields := hit.Fields