mirror of
https://github.com/moparisthebest/kaiwa
synced 2024-11-22 01:02:23 -05:00
Yay async
This commit is contained in:
parent
95e63f14dc
commit
e5cbe74069
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "otalk.im",
|
"name": "otalk.im",
|
||||||
"version": "0.0.8",
|
"version": "0.0.9",
|
||||||
"description": "Otalk: WebRTC Enabled XMPP Client, in the Browser",
|
"description": "Otalk: WebRTC Enabled XMPP Client, in the Browser",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
@ -50,6 +50,7 @@ if (config.isDev) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
clientApp.on('ready', function () {
|
clientApp.on('ready', function () {
|
||||||
|
console.log('READY!');
|
||||||
var pkginfo = JSON.parse(fs.readFileSync('./package.json'));
|
var pkginfo = JSON.parse(fs.readFileSync('./package.json'));
|
||||||
|
|
||||||
var manifestTemplate = fs.readFileSync('./clientapp/templates/misc/manifest.cache', 'utf-8');
|
var manifestTemplate = fs.readFileSync('./clientapp/templates/misc/manifest.cache', 'utf-8');
|
||||||
@ -64,6 +65,9 @@ clientApp.on('ready', function () {
|
|||||||
res.set('Cache-Control', 'no-cache, private, no-store, must-revalidate, max-stale=0, post-check=0, pre-check=0');
|
res.set('Cache-Control', 'no-cache, private, no-store, must-revalidate, max-stale=0, post-check=0, pre-check=0');
|
||||||
res.send(cacheManifest);
|
res.send(cacheManifest);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// serves app on every other url
|
||||||
|
app.get('*', clientApp.html());
|
||||||
});
|
});
|
||||||
|
|
||||||
var webappManifest = fs.readFileSync('./public/x-manifest.webapp');
|
var webappManifest = fs.readFileSync('./public/x-manifest.webapp');
|
||||||
@ -137,9 +141,6 @@ app.get('/oembed', function (req, res) {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// serves app on every other url
|
|
||||||
app.get('*', clientApp.html());
|
|
||||||
|
|
||||||
|
|
||||||
app.use(function handleError(err, req, res, next) {
|
app.use(function handleError(err, req, res, next) {
|
||||||
var errorResult = {message: 'Something bad happened :('};
|
var errorResult = {message: 'Something bad happened :('};
|
||||||
|
Loading…
Reference in New Issue
Block a user