fix(format): Ignore empty contents

This commit is contained in:
Michael Carlberg
2016-12-27 04:03:46 +01:00
parent 4bc203dd1f
commit db7aa7c490
4 changed files with 33 additions and 29 deletions

View File

@ -125,13 +125,11 @@ namespace modules {
* Output content as defined in the config
*/
bool xwindow_module::build(builder* builder, const string& tag) const {
if (tag == TAG_LABEL) {
if (tag == TAG_LABEL && m_label && m_label.get()) {
builder->node(m_label);
} else {
return false;
return true;
}
return true;
return false;
}
}