Skip to content

Commit 4afc1a8

Browse files
committed
feat: [#242] improve message after uploading when infohash changes
1 parent ab9769a commit 4afc1a8

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

pages/upload.vue

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,11 +160,17 @@ function submitForm () {
160160
.then((new_torrent) => {
161161
uploading.value = false;
162162
163+
let text = "Torrent uploaded!";
164+
165+
if (new_torrent.canonical_info_hash !== new_torrent.info_hash) {
166+
text += ` Original infohash ${new_torrent.info_hash} has changed because non-standard info dictionary fields were removed. New infohash is ${new_torrent.canonical_info_hash}`;
167+
}
168+
163169
notify({
164170
group: "success",
165171
title: "Success",
166-
text: "Torrent uploaded!"
167-
}, 4000);
172+
text
173+
}, 8000);
168174
169175
navigateTo(`/torrent/${new_torrent.canonical_info_hash}`, { replace: true });
170176
})

0 commit comments

Comments
 (0)