Skip to content

Commit ab7dbcf

Browse files
authored
Merge pull request #4951 from chromoxdor/fix-json-plugin-description-
[JSON] Fix syntax of plugin description array
2 parents 89cc954 + 8712d2f commit ab7dbcf

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed

src/src/Helpers/StringGenerator_System.cpp

+10-9
Original file line numberDiff line numberDiff line change
@@ -305,27 +305,28 @@ String formatSystemBuildNr(uint16_t buildNr) {
305305
}
306306

307307
String getPluginDescriptionString() {
308-
return F(
309-
""
308+
String result = F("["
310309
#ifdef PLUGIN_BUILD_NORMAL
311-
"[Normal]"
310+
"\"Normal\""
312311
#endif // ifdef PLUGIN_BUILD_NORMAL
313312
#ifdef PLUGIN_BUILD_COLLECTION
314-
"[Collection]"
313+
"\"Collection\""
315314
#endif // ifdef PLUGIN_BUILD_COLLECTION
316315
#ifdef PLUGIN_BUILD_DEV
317-
"[Development]"
316+
"\"Development\""
318317
#endif // ifdef PLUGIN_BUILD_DEV
319318
#ifdef PLUGIN_DESCR
320-
"[" PLUGIN_DESCR "]"
319+
"\"" PLUGIN_DESCR "\""
321320
#endif // ifdef PLUGIN_DESCR
322321
#ifdef BUILD_NO_DEBUG
323-
"[No Debug Log]"
322+
"\"No Debug Log\""
324323
#endif
325324
#if FEATURE_NON_STANDARD_24_TASKS && defined(ESP8266)
326-
"[24tasks]"
325+
"\"24tasks\""
327326
#endif // if FEATURE_NON_STANDARD_24_TASKS && defined(ESP8266)
328-
);
327+
"]");
328+
result.replace("\"\"", "\",\"");
329+
return result;
329330
}
330331

331332
String getSystemLibraryString() {

0 commit comments

Comments
 (0)