Skip to content

Commit

Permalink
improve display for magnet link dn
Browse files Browse the repository at this point in the history
  • Loading branch information
howardchung committed Feb 7, 2025
1 parent a76b32a commit 5c611af
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/App/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1839,7 +1839,10 @@ export default class App extends React.Component<AppProps, AppState> {
const magnetUrl = searchParsed.get('torrent') ?? '';
const magnetParsed = new URLSearchParams(magnetUrl);
const index = searchParsed.get('fileIndex');
return magnetParsed.get('dn') + (index != null ? ` (file ${index})` : '');
return (
(magnetParsed.get('dn') ?? searchParsed.get('dn')) +
(index != null ? ` (file ${index})` : '')
);
}
if (input.includes('/proxy')) {
const urlParsed = new URLSearchParams(input);
Expand Down

0 comments on commit 5c611af

Please sign in to comment.