fixed bug where custom paths failed to stream

This commit is contained in:
Isaac Grynsztein
2020-03-01 02:31:47 -05:00
parent 2673f4ee98
commit 62a000b631
2 changed files with 7 additions and 7 deletions

View File

@@ -74,7 +74,7 @@ export class PlayerComponent implements OnInit {
for (let i = 0; i < this.fileNames.length; i++) {
const fileName = this.fileNames[i];
const baseLocation = (this.type === 'audio') ? this.audioFolderPath : this.videoFolderPath;
const fullLocation = this.baseStreamPath + baseLocation + encodeURI(fileName); // + (this.type === 'audio' ? '.mp3' : '.mp4');
const fullLocation = this.baseStreamPath + baseLocation + encodeURIComponent(fileName);
// if it has a slash (meaning it's in a directory), only get the file name for the label
let label = null;
const decodedName = decodeURIComponent(fileName);