ebac854da8
* The MongoDB/Mongoose data storage is removed in favor of Sequelize. This abstracts over SQLite or RDBMs like PostgreSQL and MSSQL. The default is SQLite, which significantly simplifies deployments in end-user environments. * As Spacedeck now has no more mandatory server dependencies, we can wrap it in Electron and ship it as a desktop application. * Removes docker-compose.yml * First version of import UI
20 lines
430 B
JavaScript
20 lines
430 B
JavaScript
'use strict';
|
|
|
|
require('../models/db');
|
|
var config = require('config');
|
|
|
|
module.exports = (req, res, next) => {
|
|
var err = new Error('Not Found');
|
|
if (req.accepts('text/html')) {
|
|
res.status(404).render('not_found', {
|
|
title: 'Page Not Found.'
|
|
});
|
|
} else if (req.accepts('application/json')) {
|
|
res.status(404).json({
|
|
"error": "not_found"
|
|
});
|
|
} else {
|
|
res.status(404).send("Not Found.");
|
|
}
|
|
}
|