mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-02 20:16:04 +01:00
Add /me* route which redirects to /user/[userslug]* (#6063)
* Add `/me*` route which redirects to the current user's information - `/me` -> `/user/[usertslug]` - `/me/bookmarks` -> `/user/[userslug]/bookmarks` - `/me/settings` -> `/user/[userslug]/settings` etc * Add tests for `/me/*`
This commit is contained in:
committed by
Barış Soner Uşaklı
parent
643008041c
commit
f5385e38bf
@@ -186,8 +186,9 @@ describe('authentication', function () {
|
||||
url: nconf.get('url') + '/api/me',
|
||||
json: true,
|
||||
jar: jar,
|
||||
}, function (err, response, body) {
|
||||
}, function (err, res, body) {
|
||||
assert.ifError(err);
|
||||
assert.equal(res.statusCode, 401);
|
||||
assert.equal(body, 'not-authorized');
|
||||
done();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user