mirror of
https://github.com/Akif9748/akf-forum.git
synced 2024-11-22 20:10:40 +03:00
Compare commits
3 commits
bda7988000
...
aace4c6fd4
Author | SHA1 | Date | |
---|---|---|---|
aace4c6fd4 | |||
d4021e0e4a | |||
29f8af1394 |
3 changed files with 6 additions and 3 deletions
4
package-lock.json
generated
4
package-lock.json
generated
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"name": "akf-forum",
|
||||
"version": "5.5.2",
|
||||
"version": "5.6.0",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "akf-forum",
|
||||
"version": "5.5.2",
|
||||
"version": "5.6.0",
|
||||
"license": "GPL-3.0-or-later",
|
||||
"dependencies": {
|
||||
"bcrypt": "^5.1.0",
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "akf-forum",
|
||||
"version": "5.5.2",
|
||||
"version": "5.6.0",
|
||||
"description": "A Node.js based forum software",
|
||||
"main": "src/index.js",
|
||||
"scripts": {
|
||||
|
|
|
@ -5,6 +5,9 @@ const { themes, emailRegEx } = require("../../../lib")
|
|||
const app = Router();
|
||||
const { join } = require("path");
|
||||
app.param("id", async (req, res, next, id) => {
|
||||
if (id === "me")
|
||||
id = req.user.id;
|
||||
|
||||
req.member = await UserModel.get(id, req.user.admin ? "+lastSeen +ips" : "");
|
||||
|
||||
if (!req.member) return res.error(404, `We don't have any user with id ${id}.`);
|
||||
|
|
Loading…
Reference in a new issue