mirror of https://github.com/keeweb/keeweb.git
less underscore
This commit is contained in:
parent
08d7261488
commit
3341f3e7f6
|
@ -43,9 +43,9 @@ class KeyHandler {
|
|||
|
||||
offKey(key, handler, thisArg) {
|
||||
if (this.shortcuts[key]) {
|
||||
this.shortcuts[key] = _.reject(this.shortcuts[key], sh => {
|
||||
return sh.handler === handler && sh.thisArg === thisArg;
|
||||
});
|
||||
this.shortcuts[key] = this.shortcuts[key].filter(
|
||||
sh => sh.handler !== handler || sh.thisArg !== thisArg
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -183,10 +183,8 @@ Tip.hideTip = function(el) {
|
|||
Tip.updateTip = function(el, props) {
|
||||
if (el._tip) {
|
||||
el._tip.hide();
|
||||
Object.assign(
|
||||
el._tip,
|
||||
_.pick(props, ['title', 'placement', 'fast', 'showTimeout', 'hideTimeout'])
|
||||
);
|
||||
const { title, placement, fast, showTimeout, hideTimeout } = props;
|
||||
Object.assign(el._tip, { title, placement, fast, showTimeout, hideTimeout });
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue