diff options
author | Drew DeVault <sir@cmpwn.com> | 2018-10-08 14:42:48 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-08 14:42:48 +0200 |
commit | 6cb0e58c6d26efa2bca9b3710df08ed1aea09aea (patch) | |
tree | 1036293744616474f190d30f7ae5428579e82900 /sway/ipc-json.c | |
parent | b3b17280de54021657eabf2df4c3dbfd0039bac8 (diff) | |
parent | 5e1983660dddc40d60026cbd0daf96d880f24fb9 (diff) |
Merge pull request #2791 from RyanDwyer/status-command-optional
swaybar: allow null status_command
Diffstat (limited to 'sway/ipc-json.c')
-rw-r--r-- | sway/ipc-json.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sway/ipc-json.c b/sway/ipc-json.c index 7c5a0a5d..f02f370b 100644 --- a/sway/ipc-json.c +++ b/sway/ipc-json.c @@ -514,8 +514,8 @@ json_object *ipc_json_describe_bar_config(struct bar_config *bar) { json_object_new_string(bar->hidden_state)); json_object_object_add(json, "position", json_object_new_string(bar->position)); - json_object_object_add(json, "status_command", - json_object_new_string(bar->status_command)); + json_object_object_add(json, "status_command", bar->status_command ? + json_object_new_string(bar->status_command) : NULL); json_object_object_add(json, "font", json_object_new_string((bar->font) ? bar->font : config->font)); if (bar->separator_symbol) { |