mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: regression 218f5ea from via, stricter check on whether the calling user is a remote uid
This commit is contained in:
@@ -89,7 +89,7 @@ module.exports = function (Topics) {
|
||||
Topics.post = async function (data) {
|
||||
data = await plugins.hooks.fire('filter:topic.post', data);
|
||||
const { uid } = data;
|
||||
const remoteUid = !utils.isNumber(uid);
|
||||
const remoteUid = activitypub.helpers.isUri(uid);
|
||||
|
||||
const [categoryExists, canCreate, canTag, isAdmin] = await Promise.all([
|
||||
parseInt(data.cid, 10) > 0 ? categories.exists(data.cid) : true,
|
||||
|
||||
Reference in New Issue
Block a user