mirror of
https://github.com/MaciejkaG/statki.git
synced 2024-11-30 00:22:55 +01:00
Fixes
This commit is contained in:
parent
c2975bedc9
commit
4018569f7b
2
index.js
2
index.js
@ -19,6 +19,7 @@ app.set('views', './views');
|
|||||||
const server = createServer(app);
|
const server = createServer(app);
|
||||||
const io = new Server(server);
|
const io = new Server(server);
|
||||||
|
|
||||||
|
app.set('trust proxy', 1);
|
||||||
const sessionMiddleware = session({
|
const sessionMiddleware = session({
|
||||||
secret: uuidv4(),
|
secret: uuidv4(),
|
||||||
resave: true,
|
resave: true,
|
||||||
@ -31,6 +32,7 @@ app.use(express.static(path.join(__dirname, 'public')));
|
|||||||
io.engine.use(sessionMiddleware);
|
io.engine.use(sessionMiddleware);
|
||||||
|
|
||||||
app.get("/", (req, res) => {
|
app.get("/", (req, res) => {
|
||||||
|
|
||||||
res.render('index');
|
res.render('index');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -27,7 +27,6 @@ window.addEventListener("load", () => {
|
|||||||
if (elem != null) {
|
if (elem != null) {
|
||||||
switchView(elem.id, true);
|
switchView(elem.id, true);
|
||||||
activeView = elem.id;
|
activeView = elem.id;
|
||||||
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
switchView("mainMenuView");
|
switchView("mainMenuView");
|
||||||
|
@ -1,7 +1,3 @@
|
|||||||
<div class="container" id="loadingView" data-title="Statki" data-path="/">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="container" id="mainMenuView" data-title="Statki" data-path="/">
|
<div class="container" id="mainMenuView" data-title="Statki" data-path="/">
|
||||||
<div>
|
<div>
|
||||||
<h1>Statki</h1>
|
<h1>Statki</h1>
|
||||||
|
Loading…
Reference in New Issue
Block a user