فهرست منبع

Move config to apps_data

theageoflove 2 سال پیش
والد
کامیت
89b0c23ed1
1فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 2 2
      zeitraffer.c

+ 2 - 2
zeitraffer.c

@@ -7,7 +7,7 @@
 #include "gpio_item.h"
 #include "zeitraffer_icons.h"
 
-#define CONFIG_FILE_DIRECTORY_PATH "/ext/apps/Misc"
+#define CONFIG_FILE_DIRECTORY_PATH "/ext/apps_data/zeitraffer"
 #define CONFIG_FILE_PATH CONFIG_FILE_DIRECTORY_PATH "/zeitraffer.conf"
 
 // Часть кода покрадена из https://github.com/zmactep/flipperzero-hello-world
@@ -157,7 +157,7 @@ int32_t zeitraffer_app(void* p) {
 	FlipperFormat* load = flipper_format_file_alloc(storage);
   
 	do {
-
+		if(!storage_simply_mkdir(storage, CONFIG_FILE_DIRECTORY_PATH)) {notification_message(notifications, &sequence_error); break;}
 		if(!flipper_format_file_open_existing(load, CONFIG_FILE_PATH)) {notification_message(notifications, &sequence_error); break;}
 		if(!flipper_format_read_int32(load, "Time", &Time, 1)) {notification_message(notifications, &sequence_error); break;}
 		if(!flipper_format_read_int32(load, "Count", &Count, 1)) {notification_message(notifications, &sequence_error); break;}