This has been fixed in
https://github.com/discourse/discourse/commit/6edf285c893fdca4584e73a7274febcd586c665b