mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 03:59:50 +08:00
FIX: File size text should not be part of link.
This commit is contained in:
parent
fb0a655e8a
commit
e5cace9185
|
@ -444,9 +444,9 @@ export function getUploadMarkdown(upload) {
|
|||
) {
|
||||
return uploadLocation(upload.url);
|
||||
} else {
|
||||
return `[${upload.original_filename} (${I18n.toHumanSize(
|
||||
upload.filesize
|
||||
)})|attachment](${upload.short_url})`;
|
||||
return `[${upload.original_filename}|attachment](${
|
||||
upload.short_url
|
||||
}) (${I18n.toHumanSize(upload.filesize)})`;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -194,7 +194,7 @@ QUnit.test("getUploadMarkdown", assert => {
|
|||
|
||||
assert.equal(
|
||||
testUploadMarkdown("important.txt", { short_url }),
|
||||
`[important.txt (42 Bytes)|attachment](${short_url})`
|
||||
`[important.txt|attachment](${short_url}) (42 Bytes)`
|
||||
);
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user