mirror of
https://github.com/wassname/talk.git
synced 2026-08-13 12:40:11 +08:00
Initial commit of asset queuing (#97)
* Initial commit of asset queuing * Addresssing comments
This commit is contained in:
committed by
Dan Zajdband
parent
c1a7b95705
commit
b0f01cf00f
@@ -1,7 +1,6 @@
|
||||
const express = require('express');
|
||||
const Comment = require('../../../models/comment');
|
||||
const Setting = require('../../../models/setting');
|
||||
const authorization = require('../../../middleware/authorization');
|
||||
|
||||
const router = express.Router();
|
||||
|
||||
@@ -13,7 +12,7 @@ const router = express.Router();
|
||||
// depending on the settings. The :moderation overwrites this settings.
|
||||
// Pre-moderation: New comments are shown in the moderator queues immediately.
|
||||
// Post-moderation: New comments do not appear in moderation queues unless they are flagged by other users.
|
||||
router.get('/comments/pending', authorization.needed('admin'), (req, res, next) => {
|
||||
router.get('/comments/pending', (req, res, next) => {
|
||||
Setting.getModerationSetting().then(function({moderation}){
|
||||
Comment.moderationQueue(moderation).then((comments) => {
|
||||
res.status(200).json(comments);
|
||||
|
||||
Reference in New Issue
Block a user