diff --git a/screenshot.png b/screenshot.png index 68c159a3cb2f100472f6ea05a75ae672c48d8303..46c72f45099cdfd12c634265a5e5d7ce0f11899d 100644 Binary files a/screenshot.png and b/screenshot.png differ diff --git a/src/bot.ts b/src/bot.ts index 8ec1ad862021bf821470985705d51370fb3ef3eb..45bd0e36aa341a71ea04ea27198f20c8e90492cb 100644 --- a/src/bot.ts +++ b/src/bot.ts @@ -18,6 +18,7 @@ import { Provisioner } from "./provisioner"; // messages get delayed from discord. const MSG_PROCESS_DELAY = 750; const MIN_PRESENCE_UPDATE_DELAY = 250; +const AVATAR_SIZE = 512; // matrix -> discord // TODO: This is bad. We should be serving the icon from the own homeserver. const MATRIX_ICON_URL = "https://matrix.org/_matrix/media/r0/download/matrix.org/mlxoESwIsTbJrfXyAAogrNxA"; class ChannelLookupResult { @@ -167,7 +168,7 @@ export class DiscordBot { profile.displayname = profile.displayname || event.sender; if (profile.avatar_url) { const mxClient = this.bridge.getClientFactory().getClientAs(); - profile.avatar_url = mxClient.mxcUrlToHttp(profile.avatar_url); + profile.avatar_url = mxClient.mxcUrlToHttp(profile.avatar_url, AVATAR_SIZE, AVATAR_SIZE, "scale"); } /* See issue #82 const isMarkdown = (event.content.format === "org.matrix.custom.html");