[Videos] Fix uploads (#5042)
* fix pds url * fix service auth exp * whoopsie wrong branch
This commit is contained in:
parent
c60e8d0772
commit
e7954e590b
3 changed files with 12 additions and 14 deletions
|
@ -340,7 +340,7 @@ export function shortLinkToHref(url: string): string {
|
|||
}
|
||||
}
|
||||
|
||||
export function getHostnameFromUrl(url: string): string | null {
|
||||
export function getHostnameFromUrl(url: string | URL): string | null {
|
||||
let urlp
|
||||
try {
|
||||
urlp = new URL(url)
|
||||
|
@ -350,7 +350,7 @@ export function getHostnameFromUrl(url: string): string | null {
|
|||
return urlp.hostname
|
||||
}
|
||||
|
||||
export function getServiceAuthAudFromUrl(url: string): string | null {
|
||||
export function getServiceAuthAudFromUrl(url: string | URL): string | null {
|
||||
const hostname = getHostnameFromUrl(url)
|
||||
if (!hostname) {
|
||||
return null
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue