expose request in builder
This commit is contained in:
parent
c6b3051887
commit
e8a8b5976b
4 changed files with 7 additions and 9 deletions
|
|
@ -39,9 +39,7 @@ where
|
|||
if i == 0 {
|
||||
Ok(None)
|
||||
} else {
|
||||
let naive = NaiveDateTime::from_timestamp_opt(i, 0)
|
||||
.ok_or_else(|| D::Error::invalid_value(Unexpected::Signed(i), &"Epoch timestamp"))?;
|
||||
Ok(Some(DateTime::from_utc(naive, Utc)))
|
||||
Ok(DateTime::from_timestamp(i, 0))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -223,8 +223,8 @@ pub struct ApiRequestBuilder<A>
|
|||
where
|
||||
A: ApiSelection,
|
||||
{
|
||||
request: ApiRequest<A>,
|
||||
id: Option<String>,
|
||||
pub request: ApiRequest<A>,
|
||||
pub id: Option<String>,
|
||||
}
|
||||
|
||||
impl<A> Default for ApiRequestBuilder<A>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue