mirror of
https://github.com/discourse/discourse.git
synced 2025-05-30 04:07:55 +08:00
Integrate new engine, correct old specs
corrects edge cases with - full quotes - [url] with nested tags - engine overrides - onebox applying to non http srcs
This commit is contained in:
@ -227,10 +227,11 @@ export function setup(opts, siteSettings, state) {
|
||||
opts.markdownIt = true;
|
||||
opts.setup = true;
|
||||
|
||||
if (!opts.discourse.sanitizer) {
|
||||
if (!opts.discourse.sanitizer || !opts.sanitizer) {
|
||||
const whiteLister = new WhiteLister(opts.discourse);
|
||||
opts.sanitizer = opts.discourse.sanitizer = (!!opts.discourse.sanitize) ? a=>sanitize(a, whiteLister) : a=>a;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
export function cook(raw, opts) {
|
||||
|
Reference in New Issue
Block a user