mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-10-29 08:13:44 +01:00
JsonConfig: write all flags when generating config file
This commit is contained in:
@@ -147,11 +147,9 @@ void ffParseSeparatorJsonObject(FFSeparatorOptions* options, yyjson_val* module)
|
||||
|
||||
void ffGenerateSeparatorJsonConfig(FFSeparatorOptions* options, yyjson_mut_doc* doc, yyjson_mut_val* module)
|
||||
{
|
||||
__attribute__((__cleanup__(ffDestroySeparatorOptions))) FFSeparatorOptions defaultOptions;
|
||||
ffInitSeparatorOptions(&defaultOptions);
|
||||
|
||||
if (!ffStrbufEqual(&options->string, &defaultOptions.string))
|
||||
yyjson_mut_obj_add_strbuf(doc, module, "string", &options->string);
|
||||
yyjson_mut_obj_add_strbuf(doc, module, "string", &options->string);
|
||||
yyjson_mut_obj_add_strbuf(doc, module, "outputColor", &options->outputColor);
|
||||
yyjson_mut_obj_add_uint(doc, module, "length", options->length);
|
||||
}
|
||||
|
||||
void ffInitSeparatorOptions(FFSeparatorOptions* options)
|
||||
|
||||
Reference in New Issue
Block a user