Files
element-web/src
Slavi Pantaleev 3f60b4336f Do not try to request thumbnails with non-integer widths
Issue described in https://github.com/vector-im/riot-web/issues/9690.

With certain `window.devicePixelRatio` values
(e.g.  `1.5789473684210527`), the calculated thumb width/height
would be a non-integer value.

Passing such values to `client.mxcUrlToHttp()` causes it to
generate URLs to the thumbnail API with non-integer values.
As per the spec, non-integer values are forbidden for that API and a
400 HTTP response is returned (`Query parameter b'width' must be an
integer`).

Fixing matrix-js-sdk's `mxcUrlToHttp()` to sanitize such values
would also be a good idea and likely fix more than just matrix-react-sdk
and riot-web. Still, it feels like matrix-react-sdk should play nice
as well, and not request thumbnails for weird widths/heights.

Signed-off-by: Slavi Pantaleev <slavi@devture.com>
2019-05-27 11:06:10 +03:00
..
2019-05-20 10:08:34 +01:00
2019-02-04 18:38:31 +00:00
2019-05-17 17:43:08 +01:00
2019-04-08 19:12:04 +01:00
2019-05-24 10:53:24 -06:00
2019-01-31 18:52:39 -06:00
2019-02-24 01:38:31 +00:00
2019-04-12 10:37:14 +01:00
2019-01-25 16:13:30 -06:00
2019-05-15 13:47:48 +01:00
2019-04-05 11:00:25 -06:00
2019-05-16 14:43:47 +01:00
2019-04-05 10:18:41 +01:00
2019-02-04 13:40:21 -07:00
2019-01-31 18:52:39 -06:00
2019-04-03 15:29:15 -06:00
2019-03-12 10:28:47 +00:00