Delegates no longer need to implement Clone.

This commit is contained in:
Glenn Griffin
2019-11-11 08:43:40 -08:00
parent 7446200421
commit fa121d41b2
3 changed files with 6 additions and 8 deletions

View File

@@ -133,7 +133,7 @@ where
let application_secret = &self.application_secret;
let client = self.client.clone();
let wait = self.wait;
let fd = self.fd.clone();
let fd = &self.fd;
let (pollinf, device_code) = Self::request_code(
application_secret,
client.clone(),
@@ -152,7 +152,7 @@ where
client.clone(),
&device_code,
pollinf.clone(),
fd.clone(),
fd,
)
.await;
match r {
@@ -270,7 +270,7 @@ where
client: hyper::Client<C>,
device_code: &str,
pi: PollInformation,
fd: FD,
fd: &FD,
) -> Result<Option<Token>, PollError> {
if pi.expires_at <= Utc::now() {
fd.expired(&pi.expires_at);