Put stuct first since it's easier that way for the walk through.
This commit is contained in:
1 parent
e97968054d
commit
b467f77a79
1 file changed
+7
-7
+7
-7
@@ -1,6 +1,13 @@
|
||||
use serde::{Deserialize, Serialize};
|
||||
use sqlx::{types::Json, Row};
|
||||
|
||||
#[derive(Serialize, Deserialize, Debug)]
|
||||
struct Doc {
|
||||
age: u32,
|
||||
fav_color: String,
|
||||
fav_movie: String,
|
||||
}
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() -> anyhow::Result<()> {
|
||||
// Connect to the database.
|
||||
@@ -61,10 +68,3 @@ async fn main() -> anyhow::Result<()> {
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Debug)]
|
||||
struct Doc {
|
||||
age: u32,
|
||||
fav_color: String,
|
||||
fav_movie: String,
|
||||
}
|
||||
Reference in new issue
Block a user