From 727b2fc3137cc15170579c2294c5cafb9e8411cd Mon Sep 17 00:00:00 2001 From: Alexis Lahouze Date: Fri, 14 Oct 2016 09:20:02 +0200 Subject: [PATCH] Fix eslint errors again. --- accountant-ui/js/operations.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/accountant-ui/js/operations.js b/accountant-ui/js/operations.js index 1465cb3..551b155 100644 --- a/accountant-ui/js/operations.js +++ b/accountant-ui/js/operations.js @@ -115,6 +115,7 @@ angular.module('accountant.operations', [ size: '60%', dataLabels: { formatter: function() { + // eslint-disable-next-line angular/controller-as-vm return this.point.name; }, distance: -40 @@ -126,8 +127,14 @@ angular.module('accountant.operations', [ size: '60%', dataLabels: { formatter: function() { - return this.point.name !== null && this.percentage >= - 2.5 ? this.point.name : null; } + // eslint-disable-next-line angular/controller-as-vm + if (this.point.name !== null && this.percentage >= 2.5) { + // eslint-disable-next-line angular/controller-as-vm + return this.point.name; + } + + return null; + } } }] };