diff options
Diffstat (limited to 'sway/commands/bar')
-rw-r--r-- | sway/commands/bar/id.c | 2 | ||||
-rw-r--r-- | sway/commands/bar/status_command.c | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/sway/commands/bar/id.c b/sway/commands/bar/id.c index 65fa69fd..7690a852 100644 --- a/sway/commands/bar/id.c +++ b/sway/commands/bar/id.c @@ -13,6 +13,8 @@ struct cmd_results *bar_cmd_id(int argc, char **argv) { const char *oldname = config->current_bar->id; if (strcmp(name, oldname) == 0) { return cmd_results_new(CMD_SUCCESS, NULL, NULL); // NOP + } else if (strcmp(name, "id") == 0) { + return cmd_results_new(CMD_INVALID, "id", "id cannot be 'id'"); } // check if id is used by a previously defined bar for (int i = 0; i < config->bars->length; ++i) { diff --git a/sway/commands/bar/status_command.c b/sway/commands/bar/status_command.c index 5b4fdc87..490393f1 100644 --- a/sway/commands/bar/status_command.c +++ b/sway/commands/bar/status_command.c @@ -25,7 +25,7 @@ struct cmd_results *bar_cmd_status_command(int argc, char **argv) { } if (config->active && !config->validating) { - load_swaybars(); + load_swaybar(config->current_bar); } return cmd_results_new(CMD_SUCCESS, NULL, NULL); |