check hapi server status
parent
b4f3592c76
commit
3527ded36f
@ -0,0 +1,10 @@
|
||||
const fetch = require('node-fetch');
|
||||
const { Hapi } = require('../config.json');
|
||||
|
||||
module.exports = async function () {
|
||||
if (Hapi) {
|
||||
var res = await fetch(Hapi);
|
||||
return res.status === 200;
|
||||
} else
|
||||
return false;
|
||||
};
|
Loading…
Reference in New Issue