发布嵌套聊天时出错

[chat quote="How_To_Roblox;2741;2022-05-15T16:24:11Z" channel="The Chat Feedback topic"]
[chat quote="JammyDodger;2576;2022-05-14T14:04:06Z" channel="Chat on a topic test!"]
我拥有“静音用户”和“重建 HTML”选项,在选择选项中,除了常规的“在主题中引用”之外,我还有“移动到频道”选项。
[/chat]

应该添加一个“移动到主题”按钮,用于方便查找长对话或保持频道整洁。
[/chat]

尝试在帖子中粘贴上述嵌套的聊天引用时,预览中不显示,并且在“回复”时出现 500 错误。

Uncaught TypeError: t.attrs[r][1] is null
消息

MiniRacer::RuntimeError (TypeError: Cannot read properties of null (reading 'indexOf'))
lib/pretty_text.rb:242:in `block in markdown'
lib/pretty_text.rb:582:in `block in protect'
lib/pretty_text.rb:581:in `synchronize'
lib/pretty_text.rb:581:in `protect'
lib/pretty_text.rb:185:in `markdown'
lib/pretty_text.rb:314:in `cook'
lib/new_post_manager.rb:215:in `block in perform'
lib/new_post_manager.rb:214:in `any?'
lib/new_post_manager.rb:214:in `perform'
app/controllers/posts_controller.rb:196:in `create'
app/controllers/application_controller.rb:411:in `block in with_resolved_locale'
app/controllers/application_controller.rb:411:in `with_resolved_locale'
lib/middleware/omniauth_bypass_middleware.rb:71:in `call'
lib/content_security_policy/middleware.rb:12:in `call'
lib/middleware/anonymous_cache.rb:368:in `call'
config/initializers/008-rack-cors.rb:25:in `call'
config/initializers/100-quiet_logger.rb:23:in `call'
config/initializers/100-silence_logger.rb:31:in `call'
lib/middleware/enforce_hostname.rb:23:in `call'
lib/middleware/request_tracker.rb:202:in `call'

回溯

JavaScript at addImage (<anonymous>:13:31)
JavaScript at processToken (<anonymous>:74:7)
JavaScript at Array.rule (<anonymous>:92:7)
JavaScript at Core.process (<anonymous>:1384:13)
JavaScript at MarkdownIt.parse (<anonymous>:1149:13)
JavaScript at MarkdownIt.render (<anonymous>:1169:36)
JavaScript at cook (<anonymous>:578:32)
JavaScript at customRenderFn (<anonymous>:358:14)
JavaScript at replace (<anonymous>:155:23)
JavaScript at applyBBCode (<anonymous>:278:25)

环境

HTTP HOSTS: meta.discourse.org
5 个赞

经过对上述示例的快速实践测试,现在似乎已修复。:+1:

2 个赞