mirror of
https://github.com/wassname/talk.git
synced 2026-07-12 04:08:49 +08:00
10 lines
337 B
JavaScript
10 lines
337 B
JavaScript
const { ErrAssetCommentingClosed } = require('../../../errors');
|
|
|
|
// This phase checks to see if the asset being processed is closed or not.
|
|
module.exports = (ctx, comment, { asset }) => {
|
|
// Check to see if the asset has closed commenting...
|
|
if (asset.isClosed) {
|
|
throw new ErrAssetCommentingClosed(asset.closedMessage);
|
|
}
|
|
};
|