diff --git a/settings/settings.go b/settings/settings.go index 1727db99..2d4f70ed 100644 --- a/settings/settings.go +++ b/settings/settings.go @@ -48,7 +48,9 @@ func Execute(w http.ResponseWriter, r *http.Request) (int, error) { return 500, err } - commands.Execute() + w.Header().Set("Content-Type", "application/json") + w.Write([]byte("{}")) + go commands.Execute() } else { content, err := ioutil.ReadFile("config." + language) diff --git a/static/js/app.js b/static/js/app.js index 7375b563..489adc7a 100644 --- a/static/js/app.js +++ b/static/js/app.js @@ -8,9 +8,11 @@ $(document).ready(function() { url : url, data : data, dataType : 'json', - encode : true + encode : true, }).done(function(data) { - console.log(data); + alert("it workss"); + }).fail(function(data) { + alert("it failed"); }); event.preventDefault();