Mattermost-server: Line breaks are ignored when used with inline images.

Created on 4 Feb 2020  路  6Comments  路  Source: mattermost/mattermost-server

Summary

Line breaks are ignored when used with inline images.
Message preview does show the right formatting
preview_msg
but when send it ignores the new lines.
broken_msg

Occured with the update to Mattermost 5.18.1, still there in 5.19.1.

Steps to reproduce

  1. Use Mattermost >= 5.18.1
  2. Type the follwing message:
![embeddedimage](https://mattermost.com/wp-content/themes/mattermostv3/favicon-16x16.png) This is in the same line as the image.
This is in a new line.

This is in a new line with a free line between all previuos text and this line.
  1. Send it.

Expected behavior

It should respect the new line auf the text part "This is in a new line." and look like in the message preview.

Observed behavior

The part "This is in a new line." is appended to the previous line, ignoring the line break.

Bug ReporOpen

Most helpful comment

All 6 comments

Closing as this will be fixed in v5.22,

@amyblais actually this is not fixed, not even in the latest version. When I initially upgraded our server I thought our installation could be broken, but a weak ago I installed the 5.25.1 and it is still broken. I then did a fresh test install and still no luck. Checked the jira ticked and saw it was closed and marked as a duplicate, but apparently the other thing wasnt linked to this problem as assumed. Could you please reopen and/or reevaluate the problem?

Thanks, I reopened the Jira ticket,

Hi,
I have an issue to add new line in any messages shared using the api.
In the Mattermost Version: 5.25.1 the character \n, does not add a new line anymore in the final shared message. This was working in the previous mattermost api version.
Any update on this?

Ps. I can confirm that it is ignored when an image like Mattermost is added in the message, before.

Thanks.

Hi,
I have an issue to add new line in any messages shared using the api.
In the Mattermost Version: 5.25.1 the character \n, does not add a new line anymore in the final shared message. This was working in the previous mattermost api version.
Any update on this?

Noticing this on 4.2.1 as well. \n is not rendered as a new line.

Was this page helpful?
0 / 5 - 0 ratings