changeset 5f9363fcdf4f in sao:default
details: https://hg.tryton.org/sao?cmd=changeset;node=5f9363fcdf4f
description:
Do not set 'undefined' as button class
The precedence between the + operator and the || makes that the
undefined size
is appended to the class string instead of the empty string.
issue9499
review310111002
diffstat:
src/common.js | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diffs (12 lines):
diff -r ac7a032a713f -r 5f9363fcdf4f src/common.js
--- a/src/common.js Fri Jul 31 10:33:56 2020 +0200
+++ b/src/common.js Mon Aug 03 00:03:15 2020 +0200
@@ -781,7 +781,7 @@
}).prependTo(this.el);
this.icon.hide();
}
- this.el.addClass('btn btn-default ' + size || '');
+ this.el.addClass('btn btn-default ' + (size || ''));
this.el.attr('type', 'button');
this.icon.attr('aria-hidden', true);
this.set_icon(attributes.icon);