Commit e01231d9 authored by Indrek Jentson's avatar Indrek Jentson

Runtime-check teenusele lisatud serveri ühenduse kontroll

Signed-off-by: Indrek Jentson's avatarIndrek Jentson <indrek.jentson@ut.ee>
parent 190b4d85
......@@ -78,9 +78,9 @@ var CheckService = function(){
return new Promise( function(resolve, reject) {
try {
request.get(config.serverUrl + ':3000', function(err, replay) {
if (err) resolve({type:'ERR', msg: 'ühendus serveriga ' + config.serverUr + ' ei tööta: ' + err});
if (err) resolve({type:'ERR', msg: 'ühendus serveriga ' + config.serverUrl + ' ei tööta: ' + err});
else {
resolve({type:'OK', msg: 'ühendus serveriga ' + config.serverUr + ' töötab'});
resolve({type:'OK', msg: 'ühendus serveriga ' + config.serverUrl + ' töötab'});
}
});
} catch (err) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment