Преглед изворни кода

ensure web_crawler folder is created

jblanked пре 1 година
родитељ
комит
70724ca29d
1 измењених фајлова са 3 додато и 1 уклоњено
  1. 3 1
      flip_storage/web_crawler_storage.c

+ 3 - 1
flip_storage/web_crawler_storage.c

@@ -385,11 +385,13 @@ bool save_char(
     }
     // Create the directory for saving settings
     char directory_path[256];
-    snprintf(directory_path, sizeof(directory_path), STORAGE_EXT_PATH_PREFIX "/apps_data/web_crawler/data");
+    snprintf(directory_path, sizeof(directory_path), STORAGE_EXT_PATH_PREFIX "/apps_data/web_crawler");
 
     // Create the directory
     Storage *storage = furi_record_open(RECORD_STORAGE);
     storage_common_mkdir(storage, directory_path);
+    snprintf(directory_path, sizeof(directory_path), STORAGE_EXT_PATH_PREFIX "/apps_data/web_crawler/data");
+    storage_common_mkdir(storage, directory_path);
 
     // Open the settings file
     File *file = storage_file_alloc(storage);