mirror of
https://github.com/sussy-code/smov.git
synced 2024-12-29 16:07:40 +01:00
Prevent language duplication in search
This commit is contained in:
parent
c7b361bcac
commit
83bc9637b0
1 changed files with 4 additions and 2 deletions
|
@ -130,10 +130,12 @@ export function CaptionsView({ id }: { id: string }) {
|
|||
[selectLanguage, setCurrentlyDownloading]
|
||||
);
|
||||
|
||||
const content = subtitleList.map((v) => {
|
||||
const content = subtitleList.map((v, i) => {
|
||||
return (
|
||||
<CaptionOption
|
||||
key={v.language}
|
||||
// key must use index to prevent url collisions
|
||||
// eslint-disable-next-line react/no-array-index-key
|
||||
key={`${i}-${v.url}`}
|
||||
countryCode={v.language}
|
||||
selected={lang === v.language}
|
||||
loading={v.language === currentlyDownloading && downloadReq.loading}
|
||||
|
|
Loading…
Reference in a new issue