Fixed Preview image only post

Affected version


Active member
Insert an image into a new post. Only image, nothing else, then click the Preview button.
When you are in the Preview mode, delete the image by clicking on the trash icon on the thumbnail.
You stuck with the Preview mode. It doesn't go back to the edit mode anymore.

Possible reason: as soon as you delete the image, the image BB code is deleted in the hidden editor and it has zero length content now. And Preview button wouldn't work with zero content.

XF Bug Bot

XenForo bug fixer bot
Staff member
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.2.1).

Change log:
Only bail out of toggling the editor preview when the editor is empty if you are not already previewing.
There may be a delay before changes are rolled out to the XenForo Community.