user_id: Some(inserted_user.id),
my_vote: Some(1),
id: inserted_post.id,
- name: post_name.to_owned(),
+ name: post_name,
url: None,
body: None,
removed: false,
locked: false,
stickied: false,
creator_id: inserted_user.id,
- creator_name: user_name.to_owned(),
+ creator_name: user_name,
creator_avatar: None,
banned: false,
banned_from_community: false,
community_id: inserted_community.id,
- community_name: community_name.to_owned(),
+ community_name,
community_removed: false,
community_deleted: false,
community_nsfw: false,
"engineStrict": true,
"husky": {
"hooks": {
- "pre-commit": "lint-staged"
+ "pre-commit": "cargo fmt --manifest-path ../server/Cargo.toml && cargo clippy --manifest-path ../server/Cargo.toml --all-targets --all-features -- -D warnings && lint-staged"
}
},
"lint-staged": {
"eslint --fix",
"git add"
],
+ "../server/src/**/*.rs": [
+ "git add"
+ ],
"package.json": [
"sortpack",
"git add"