aboutsummaryrefslogtreecommitdiffhomepage
path: root/fever
diff options
context:
space:
mode:
authorGravatar Frédéric Guillot <fred@miniflux.net>2018-05-21 12:19:56 -0700
committerGravatar Frédéric Guillot <fred@miniflux.net>2018-05-21 19:58:36 -0400
commitb270159aae97359afe02f3c4843fa0f4e9a1a1b6 (patch)
tree290eef118ce6ccab49471d3673bb7d51b24bb4c2 /fever
parent44decae557a6f78eda57b8f407d35b10233538e4 (diff)
Offer the possibility to set Pocket Consumer Key as environment variable
Diffstat (limited to 'fever')
-rw-r--r--fever/fever.go8
1 files changed, 5 insertions, 3 deletions
diff --git a/fever/fever.go b/fever/fever.go
index 5d0109d..7aa4885 100644
--- a/fever/fever.go
+++ b/fever/fever.go
@@ -10,6 +10,7 @@ import (
"strings"
"time"
+ "github.com/miniflux/miniflux/config"
"github.com/miniflux/miniflux/http/context"
"github.com/miniflux/miniflux/http/request"
"github.com/miniflux/miniflux/http/response/json"
@@ -128,6 +129,7 @@ type favicon struct {
// Controller implements the Fever API.
type Controller struct {
+ cfg *config.Config
store *storage.Storage
}
@@ -528,7 +530,7 @@ func (c *Controller) handleWriteItems(w http.ResponseWriter, r *http.Request) {
}
go func() {
- integration.SendEntry(entry, settings)
+ integration.SendEntry(c.cfg, entry, settings)
}()
}
@@ -642,6 +644,6 @@ func (c *Controller) buildFeedGroups(feeds model.Feeds) []feedsGroups {
}
// NewController returns a new Fever API.
-func NewController(store *storage.Storage) *Controller {
- return &Controller{store: store}
+func NewController(cfg *config.Config, store *storage.Storage) *Controller {
+ return &Controller{cfg, store}
}