mirror of
https://github.com/miniflux/v2.git
synced 2025-08-01 17:38:37 +00:00
Minor improvements in integration package
This commit is contained in:
parent
34dd358eb0
commit
49119eff00
16 changed files with 57 additions and 108 deletions
|
@ -16,6 +16,11 @@ type Client struct {
|
|||
accessToken string
|
||||
}
|
||||
|
||||
// NewClient returns a new Pocket client.
|
||||
func NewClient(consumerKey, accessToken string) *Client {
|
||||
return &Client{consumerKey, accessToken}
|
||||
}
|
||||
|
||||
// AddURL sends a single link to Pocket.
|
||||
func (c *Client) AddURL(link, title string) error {
|
||||
if c.consumerKey == "" || c.accessToken == "" {
|
||||
|
@ -48,8 +53,3 @@ func (c *Client) AddURL(link, title string) error {
|
|||
|
||||
return nil
|
||||
}
|
||||
|
||||
// NewClient returns a new Pocket client.
|
||||
func NewClient(consumerKey, accessToken string) *Client {
|
||||
return &Client{consumerKey, accessToken}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue