pipedrive
pipedrive copied to clipboard
Very short margin on OAuth token refresh
It seems that an access token is only refreshed if it actually expired already, or will expire within the next 1 second: https://github.com/IsraelOrtuno/pipedrive/blob/cc5fee011ef4e836ce60aa97d2a8a51c9645a633/src/PipedriveToken.php#L125
This seems to be a very short window given that there can easily be a time difference between systems. Is there a specific reason that this was set to such a short timeframe, or would it be okay to submit a PR to change it to a minute? With the access tokens being valid for 1 hour, that's still plenty of margin.
Changing it to a minute would make sense to me, happy to submit a PR?