Max_oneboxes_per_post is not honored in the composer preview

AI-generated summary

RGJ reports a UX issue where the max_oneboxes_per_post setting is not respected in the composer preview. This causes the preview to inaccurately represent the final post and renders disabling oneboxes for security purposes ineffective for authors. To reproduce, set max_oneboxes_per_post to zero and include a YouTube URL in a new post; the onebox will still appear in the preview despite the limit.

Problem

The setting max_oneboxes_per_post is not being honored in the composer preview.

Consequences

  • the preview is not an accurate representation of what the post will look like
  • disabling oneboxes for security reasons will not have any effect for post authors

Reproduction

Set max_oneboxes_per_post to zero, create a post with contents below and see what happens

https://www.youtube.com/watch?v=3BFTio5296w&list=RD3BFTio5296w&index=1
1 Like