fix(script): clear output when exec-if fails (#2675)

Fixes #2674
This commit is contained in:
Maxim Kolesnikov 2022-04-04 17:49:13 +07:00 committed by GitHub
parent 77d611c03d
commit 9b28ba7a5e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 1 deletions

View File

@ -9,6 +9,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [Unreleased]
### Fixed
- `custom/script`: Output clearing when `exec-if` fails ([`#2674`](https://github.com/polybar/polybar/issues/2674))
## [3.6.2] - 2022-04-03
### Fixed

View File

@ -45,7 +45,10 @@ script_runner::interval script_runner::process() {
}
void script_runner::clear_output() {
set_output("");
auto changed = set_output("");
if (changed) {
m_on_update(m_data);
}
}
void script_runner::stop() {