We received the following bugreport: https://github.com/profanity-im/profanity/issues/1254
That seems only to happen with openfire.
It seems the ‘from’ tag of MUC history is not set to the room jid as described in https://github.com/profanity-im/profanity/issues/1254.
"“The ‘from’ attribute MUST be set to the JID of the room itself.”
In the example of the user this is not the case.