File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 11import videojs from 'video.js' ;
22import 'assets/styles/components/title-bar.scss' ;
33import componentUtils from '../component-utils' ;
4+ import { utf8ToBase64 } from '../../utils/utf8Base64' ;
45import { getCloudinaryUrlPrefix } from 'plugins/cloudinary/common' ;
56
67// support VJS5 & VJS6 at the same time
@@ -46,9 +47,13 @@ class TitleBar extends Component {
4647
4748 const urlPrefix = getCloudinaryUrlPrefix ( config ) ;
4849 const deliveryType = source . getInitOptions ( ) . type || 'upload' ;
49- const metadataUrl = `${ urlPrefix } /_applet_/video_service/video_metadata/${ deliveryType } /${ publicId } .json` ;
50+ const metadataUrl = `${ urlPrefix } /_applet_/video_service/video_metadata/${ deliveryType } /${ utf8ToBase64 ( publicId ) } .json` ;
5051
51- fetch ( metadataUrl )
52+ fetch ( metadataUrl , {
53+ headers : {
54+ 'X-Cld-Video-Player-Version' : VERSION
55+ }
56+ } )
5257 . then ( response => {
5358 if ( ! response . ok ) throw new Error ( `HTTP ${ response . status } ` ) ;
5459 return response . json ( ) ;
You can’t perform that action at this time.
0 commit comments