Compare commits

..

2 Commits

Author SHA1 Message Date
Justine Pelletreau
e49efa4b64 Merge branch 'main' of ssh://docker.sq.lan:3022/Rust/SqPad 2023-07-03 17:10:11 +02:00
Justine Pelletreau
e67bfe9b58 Create posts file if it does not exist 2023-07-03 17:10:05 +02:00

View File

@ -46,6 +46,7 @@ fn save_post(text: &str) {
let mut file = OpenOptions::new()
.write(true)
.append(true)
.create(true)
.open("./Files/posts.json")
.unwrap();