refactor: make pmapi.Client the interface

This commit is contained in:
James Houlahan
2020-04-06 16:02:37 +02:00
parent 6e38a65bd8
commit f269be4291
34 changed files with 806 additions and 856 deletions

View File

@ -44,7 +44,7 @@ type UserSettings struct {
}
// GetUserSettings gets general settings.
func (c *Client) GetUserSettings() (settings UserSettings, err error) {
func (c *client) GetUserSettings() (settings UserSettings, err error) {
req, err := c.NewRequest("GET", "/settings", nil)
if err != nil {
@ -98,7 +98,7 @@ type MailSettings struct {
}
// GetMailSettings gets contact details specified by contact ID.
func (c *Client) GetMailSettings() (settings MailSettings, err error) {
func (c *client) GetMailSettings() (settings MailSettings, err error) {
req, err := c.NewRequest("GET", "/settings/mail", nil)
if err != nil {