Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
keeleliin
keeleliin-wrapper
Commits
26fa0b7a
Commit
26fa0b7a
authored
Mar 02, 2019
by
Indrek Jentson
Browse files
Runtime-check teenusele lisatud serveri ühenduse kontroll, timeout fix
Signed-off-by:
Indrek Jentson
<
indrek.jentson@ut.ee
>
parent
e01231d9
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/service/checkService.js
View file @
26fa0b7a
...
...
@@ -77,7 +77,7 @@ var CheckService = function(){
this
.
checkServer
=
function
()
{
return
new
Promise
(
function
(
resolve
,
reject
)
{
try
{
request
.
get
(
config
.
serverUrl
+
'
:3000
'
,
function
(
err
,
replay
)
{
request
.
get
(
{
url
:
config
.
serverUrl
+
'
:3000
'
,
timeout
:
5000
},
function
(
err
,
replay
)
{
if
(
err
)
resolve
({
type
:
'
ERR
'
,
msg
:
'
ühendus serveriga
'
+
config
.
serverUrl
+
'
ei tööta:
'
+
err
});
else
{
resolve
({
type
:
'
OK
'
,
msg
:
'
ühendus serveriga
'
+
config
.
serverUrl
+
'
töötab
'
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment