From 6b186a09bb90e6b5394dfde46844b4cf1db3bb76 Mon Sep 17 00:00:00 2001 From: Suresh Alse Date: Tue, 31 Oct 2017 11:48:03 -0700 Subject: [PATCH] Replacing tabs with spaces. Fix https://github.com/alseambusher/crontab-ui/issues/54 --- crontab.js | 4 ++-- views/index.ejs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/crontab.js b/crontab.js index 3fd0faa..b32887a 100644 --- a/crontab.js +++ b/crontab.js @@ -130,8 +130,8 @@ exports.set_crontab = function(env_vars, callback){ else callback(); }); } else { - callback(); - } + callback(); + } }); }); }); diff --git a/views/index.ejs b/views/index.ejs index ee9be6d..a972b39 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -14,7 +14,7 @@ $(function () { // initialize tooltips $('[data-toggle="tooltip"]').tooltip(); - crontabs = JSON.parse('<%- crontabs.replace(/\\\\/g, "\\\\\\\\").replace(/\\\"/g,"\\\\\"").replace(/\'/g,"\\\'") %>'); + crontabs = JSON.parse('<%- crontabs.replace(/\\\\/g, "\\\\\\\\").replace(/\\\"/g,"\\\\\"").replace(/\'/g,"\\\'").replace(/\\t/g, " ") %>'); routes = JSON.parse('<%- routes %>'); $("#env_vars").val(`<%- env %>`); })