Experiment with caching

This commit is contained in:
Robin 2021-01-23 10:48:33 +01:00
parent baf7272cfd
commit 077c222a4e
7 changed files with 108 additions and 8 deletions

View file

@ -54,7 +54,7 @@ async fn user(name: &str) -> Result<User, String> {
let path: String = format!("/user/{}/about.json", name);
// Send a request to the url
match request(&path).await {
match request(path).await {
// If success, receive JSON in response
Ok(res) => {
// Grab creation date as unix timestamp