changeset b072c0cb0d59 in sao:5.4
details: https://hg.tryton.org/sao?cmd=changeset;node=b072c0cb0d59
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
(grafted from 5f9363fcdf4feb3a25effc2b8f4db50ed272cba9)
diffstat:
src/common.js | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diffs (12 lines):
diff -r c7e87bcc6c2a -r b072c0cb0d59 src/common.js
--- a/src/common.js Sun Aug 02 17:31:24 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);