tisonkun commented on code in PR #643:
URL: https://github.com/apache/opendal-reqsign/pull/643#discussion_r2400506310


##########
services/azure-storage/src/provide_credential/azure_pipelines.rs:
##########
@@ -233,12 +233,12 @@ impl ProvideCredential for 
AzurePipelinesCredentialProvider {
             .await?;
 
         // Calculate expiration time
-        let expires_in = 
std::time::Duration::from_secs(token_response.expires_in);
-        let expires_on = now().checked_add(expires_in).ok();
+        let expires_in = Duration::from_secs(token_response.expires_in);
+        let expires_on = Timestamp::now() + expires_in;

Review Comment:
   We use add almost everywhere. So I'd use add first and leave whether to use 
add or checked_add a follow-up.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to