diff --git a/src/routes/media.nim b/src/routes/media.nim index 95446a1..e63a0f8 100644 --- a/src/routes/media.nim +++ b/src/routes/media.nim @@ -94,7 +94,7 @@ proc createMediaRouter*(cfg: Config) = url.insert(twimg) if not url.startsWith(https): url.insert(https) - url.add(":orig") + url.add("?name=orig") let uri = parseUri(url) cond isTwitterUrl(uri) == true diff --git a/src/views/tweet.nim b/src/views/tweet.nim index e64f959..51d427f 100644 --- a/src/views/tweet.nim +++ b/src/views/tweet.nim @@ -10,7 +10,7 @@ import general proc getSmallPic(url: string): string = result = url if "?" notin url and not url.endsWith("placeholder.png"): - result &= ":small" + result &= "?name=small" result = getPicUrl(result) proc renderMiniAvatar(user: User; prefs: Prefs): VNode = @@ -58,7 +58,7 @@ proc renderAlbum(tweet: Tweet): VNode = let named = "name=" in photo orig = photo - small = if named: photo else: photo & ":small" + small = if named: photo else: photo & "?name=small" a(href=getOrigPicUrl(orig), class="still-image", target="_blank"): genImg(small)