mirror of https://github.com/morpheus65535/bazarr
Fixed movies subtitles paths being shown in UI without being mapped.
This commit is contained in:
parent
11fb78fafa
commit
d562faf151
|
@ -159,6 +159,7 @@ def postprocessEpisode(item):
|
|||
"code2": subtitle[0],
|
||||
"code3": alpha3_from_alpha2(subtitle[0]),
|
||||
"path": subs[1],
|
||||
"mapped_path": path_mappings.path_replace(subs[1]),
|
||||
"forced": False,
|
||||
"hi": False}
|
||||
if len(subtitle) > 1:
|
||||
|
@ -225,6 +226,7 @@ def postprocessMovie(item):
|
|||
for i, subs in enumerate(item['subtitles']):
|
||||
language = subs[0].split(':')
|
||||
item['subtitles'][i] = {"path": subs[1],
|
||||
"mapped_path": path_mappings.path_replace_movie(subs[1]),
|
||||
"name": language_from_alpha2(language[0]),
|
||||
"code2": language[0],
|
||||
"code3": alpha3_from_alpha2(language[0]),
|
||||
|
|
|
@ -37,6 +37,7 @@ interface Subtitle extends Language {
|
|||
forced: boolean;
|
||||
hi: boolean;
|
||||
path: string | null;
|
||||
mapped_path: string | null;
|
||||
}
|
||||
|
||||
interface PathType {
|
||||
|
|
|
@ -32,7 +32,7 @@ const Table: FunctionComponent<Props> = ({ movie, profile }) => {
|
|||
} else if (row.value === missingText) {
|
||||
return <span className="text-muted">{row.value}</span>;
|
||||
} else {
|
||||
return row.value;
|
||||
return row.row.original.mapped_path;
|
||||
}
|
||||
},
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue