closes https://github.com/NodeBB/NodeBB/issues/4594, closes https://github.com/NodeBB/NodeBB/issues/4441
parent
a0afe6a6aa
commit
182a07ddb4
@ -0,0 +1,16 @@
|
||||
'use strict';
|
||||
|
||||
var S = require.main.require('string');
|
||||
|
||||
var library = {};
|
||||
|
||||
library.getTeasers = function(data, callback) {
|
||||
data.teasers.forEach(function(teaser) {
|
||||
if (teaser && teaser.content) {
|
||||
teaser.content = S(teaser.content).stripTags('img').s;
|
||||
}
|
||||
});
|
||||
callback(null, data);
|
||||
};
|
||||
|
||||
module.exports = library;
|
Loading…
Reference in New Issue