mirror of
https://github.com/miniflux/v2.git
synced 2025-09-30 19:22:11 +00:00
refactor: avoid unnecessary usage of Printf
This commit is contained in:
parent
d70817e441
commit
84078c7c20
6 changed files with 8 additions and 7 deletions
|
@ -50,7 +50,7 @@ func (c *Client) SaveURL(entryURL string) error {
|
|||
return fmt.Errorf("karakeep: unable to create request: %v", err)
|
||||
}
|
||||
|
||||
req.Header.Set("Authorization", fmt.Sprintf("Bearer %s", c.apiToken))
|
||||
req.Header.Set("Authorization", "Bearer "+c.apiToken)
|
||||
req.Header.Set("Content-Type", "application/json")
|
||||
req.Header.Set("User-Agent", "Miniflux/"+version.Version)
|
||||
|
||||
|
|
|
@ -90,7 +90,7 @@ func (c *Client) makeRequest(payload any) error {
|
|||
|
||||
// See https://docs.ntfy.sh/publish/#access-tokens
|
||||
if c.ntfyApiToken != "" {
|
||||
request.Header.Set("Authorization", fmt.Sprintf("Bearer %s", c.ntfyApiToken))
|
||||
request.Header.Set("Authorization", "Bearer "+c.ntfyApiToken)
|
||||
}
|
||||
|
||||
// See https://docs.ntfy.sh/publish/#username-password
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue