See description of https://github.com/matrix-org/matrix-js-sdk/pull/1112#issue-351540830 for more info