From 2d6466c2955e86af478b0db6af5c17b8e1dfda67 Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Fri, 17 Jul 2015 09:04:26 -0400 Subject: [PATCH] Fixed JavaScript "comma-spacing" violations. --- .eslintrc | 2 +- .../contrib/admin/static/admin/js/admin/DateTimeShortcuts.js | 4 ++-- django/contrib/admin/static/admin/js/calendar.js | 2 +- django/contrib/gis/static/gis/js/OLMapWidget.js | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.eslintrc b/.eslintrc index a731637d81..fda687b24e 100644 --- a/.eslintrc +++ b/.eslintrc @@ -1,7 +1,7 @@ { "rules": { "camelcase": [1, {"properties": "always"}], - "comma-spacing": [1, {"before": false, "after": true}], + "comma-spacing": [2, {"before": false, "after": true}], "dot-notation": [1, {"allowKeywords": true}], "curly": [2, "all"], "indent": [ diff --git a/django/contrib/admin/static/admin/js/admin/DateTimeShortcuts.js b/django/contrib/admin/static/admin/js/admin/DateTimeShortcuts.js index f7d1bd0ec7..648b33b3ef 100644 --- a/django/contrib/admin/static/admin/js/admin/DateTimeShortcuts.js +++ b/django/contrib/admin/static/admin/js/admin/DateTimeShortcuts.js @@ -166,7 +166,7 @@ var DateTimeShortcuts = { // Recalculate the clockbox position // is it left-to-right or right-to-left layout ? - if (getStyle(document.body,'direction')!=='rtl') { + if (getStyle(document.body, 'direction') !== 'rtl') { clock_box.style.left = findPosX(clock_link) + 17 + 'px'; } else { @@ -304,7 +304,7 @@ var DateTimeShortcuts = { // Recalculate the clockbox position // is it left-to-right or right-to-left layout ? - if (getStyle(document.body,'direction')!=='rtl') { + if (getStyle(document.body, 'direction') !== 'rtl') { cal_box.style.left = findPosX(cal_link) + 17 + 'px'; } else { diff --git a/django/contrib/admin/static/admin/js/calendar.js b/django/contrib/admin/static/admin/js/calendar.js index 841256fe0f..4eb28af461 100644 --- a/django/contrib/admin/static/admin/js/calendar.js +++ b/django/contrib/admin/static/admin/js/calendar.js @@ -12,7 +12,7 @@ var CalendarNamespace = { isLeapYear: function(year) { return (((year % 4)===0) && ((year % 100)!==0) || ((year % 400)===0)); }, - getDaysInMonth: function(month,year) { + getDaysInMonth: function(month, year) { var days; if (month===1 || month===3 || month===5 || month===7 || month===8 || month===10 || month===12) { days = 31; diff --git a/django/contrib/gis/static/gis/js/OLMapWidget.js b/django/contrib/gis/static/gis/js/OLMapWidget.js index 7d9c0a75f0..40ff139996 100644 --- a/django/contrib/gis/static/gis/js/OLMapWidget.js +++ b/django/contrib/gis/static/gis/js/OLMapWidget.js @@ -114,7 +114,7 @@ var wktArray = OpenLayers.String.trim(str).split('|'); var components = []; for(var i=0, len=wktArray.length; i