13 lines
266 B
JavaScript
13 lines
266 B
JavaScript
const express = require("express"),
|
|
router = express.Router();
|
|
|
|
const { isAdmin } = require("../utils/functions");
|
|
|
|
router.get("/", isAdmin, async (req, res) => {
|
|
res.render("admin", {
|
|
user: req.user,
|
|
locals: req.app.locals,
|
|
});
|
|
});
|
|
|
|
module.exports = router;
|