gabor-boros / minutes

Sync worklogs between multiple time trackers, invoicing, and bookkeeping software.
https://gabor-boros.github.io/minutes/
MIT License
27 stars 2 forks source link

Refactor client composition logic and remove unnecessary Toggl flag #30

Closed gabor-boros closed 3 years ago

gabor-boros commented 3 years ago

Description

This PR does a major refactor on how the client composition is done and simplify client logic. Besides that, this commit reduces the duplicated logic across clients and outsources the authentication setter.

Additionally, it makes it easier to integrate new clients with more complex authentication methods, like Oauth2.

Also, the commit contains a change that removes the illogical flag for setting Toggl Track client base URL, hence that never changes.

Supporting information

N/A

Dependencies

N/A

Screenshots

N/A

Testing instructions

Other information

This PR is kind of a requirement for integrating Zoho Books and other targets later on.

Checklist

codeclimate[bot] commented 3 years ago

Code Climate has analyzed commit 41398f58 and detected 2 issues on this pull request.

Here's the issue category breakdown:

Category Count
Duplication 2

The test coverage on the diff in this pull request is 91.8% (75% is the threshold).

This pull request will bring the total coverage in the repository to 78.8% (0.5% change).

View more on Code Climate.