Compare commits

...

3 commits

Author SHA1 Message Date
aace4c6fd4 5.6.0 2023-08-25 13:46:04 +03:00
d4021e0e4a Merge branch 'main' of https://github.com/Akif9748/akf-forum 2023-08-25 13:45:59 +03:00
29f8af1394 Added me support for ID's 2023-08-25 13:45:55 +03:00
3 changed files with 6 additions and 3 deletions

4
package-lock.json generated
View file

@ -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",

View file

@ -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": {

View file

@ -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}.`);