in filesystem_init, handle the error code correctly

This commit is contained in:
Alex Maestas 2024-08-05 23:09:24 +00:00
parent 7000d08ba5
commit ca1da33b82

View file

@ -120,7 +120,7 @@ bool filesystem_init(void) {
printf("Ignore that error! Formatting filesystem...\r\n");
err = lfs_format(&lfs, &cfg);
if (err < 0) return false;
err = lfs_mount(&lfs, &cfg) == LFS_ERR_OK;
err = lfs_mount(&lfs, &cfg);
printf("Filesystem mounted with %ld bytes free.\r\n", filesystem_get_free_space());
}