From 71d7c3f17d428a2e90fe20b6450a113b71a01536 Mon Sep 17 00:00:00 2001 From: Carlos Jimenez Ruiz Date: Wed, 18 Dec 2019 12:49:20 +0100 Subject: [PATCH] eslint rules applyed --- front/core/components/snackbar/snackbar.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/front/core/components/snackbar/snackbar.js b/front/core/components/snackbar/snackbar.js index 4106ffedd..2c794bdae 100644 --- a/front/core/components/snackbar/snackbar.js +++ b/front/core/components/snackbar/snackbar.js @@ -46,11 +46,11 @@ export default class Controller extends Component { let parent = this.snackbar.querySelectorAll('.shape')[0]; - if (parent) { + if (parent) this.snackbar.insertBefore(shape, parent); - } else { + else this.snackbar.appendChild(shape); - } + return shape; } @@ -108,11 +108,10 @@ export default class Controller extends Component { } onButtonClick(shape) { - if (this.actionHandler) { + if (this.actionHandler) this.actionHandler(); - } else { + else this.hide(shape); - } } } Controller.$inject = ['$element', '$translate'];