mirror of
https://github.com/movie-web/movie-web.git
synced 2024-12-26 18:41:51 +01:00
Improve config parsing of cdn replacements
This commit is contained in:
parent
23c1df5aef
commit
d73a9575bd
@ -89,7 +89,12 @@ export function conf(): RuntimeConfig {
|
|||||||
.filter((v) => v.length > 0), // Should be comma-seperated and contain the media type and ID, formatted like so: movie-753342,movie-753342,movie-753342
|
.filter((v) => v.length > 0), // Should be comma-seperated and contain the media type and ID, formatted like so: movie-753342,movie-753342,movie-753342
|
||||||
CDN_REPLACEMENTS: getKey("CDN_REPLACEMENTS", "")
|
CDN_REPLACEMENTS: getKey("CDN_REPLACEMENTS", "")
|
||||||
.split(",")
|
.split(",")
|
||||||
.map((v) => v.split(":").map((s) => s.trim()))
|
.map((v) =>
|
||||||
|
v
|
||||||
|
.split(":")
|
||||||
|
.map((s) => s.trim())
|
||||||
|
.filter((s) => s.length > 0),
|
||||||
|
)
|
||||||
.filter((v) => v.length > 0), // The format is <beforeA>:<afterA>,<beforeB>:<afterB>
|
.filter((v) => v.length > 0), // The format is <beforeA>:<afterA>,<beforeB>:<afterB>
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user