mirror of
https://github.com/PretendoNetwork/miiverse-api.git
synced 2026-07-13 06:50:52 -05:00
Added additional check when someone attempts to post to Announcements
This commit is contained in:
parent
be8c009b2a
commit
a161df8925
|
|
@ -23,6 +23,8 @@ router.post('/', upload.none(), async function (req, res, next) {
|
|||
{
|
||||
let user = await util.data.processUser(pid);
|
||||
let community = await database.getCommunityByTitleID(paramPackData.title_id)
|
||||
if(community.community_id === 'announcements')
|
||||
return res.sendStatus(403)
|
||||
let appData = "";
|
||||
if (req.body.app_data) {
|
||||
appData = req.body.app_data.replace(/\0/g, "").replace(/\r?\n|\r/g, "").trim();
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user