mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Fix URL parsing bug for __defaultVhost__. v5.0.55
This commit is contained in:
parent
b009860b11
commit
dd37a041b9
6 changed files with 151 additions and 34 deletions
|
@ -584,8 +584,10 @@ scApp.filter('sc_filter_streamURL', function(){
|
|||
|
||||
const pos = v.url.lastIndexOf('/');
|
||||
const stream = pos < 0 ? '' : v.url.substr(pos);
|
||||
|
||||
// Use name or extract from url.
|
||||
const streamName = v.name ? v.name : stream;
|
||||
let streamName = v.name ? v.name : stream;
|
||||
if (streamName && streamName.indexOf('/') !== 0) streamName = `/${streamName}`;
|
||||
|
||||
const pos2 = v.tcUrl.indexOf('?');
|
||||
const tcUrl = pos2 < 0 ? v.tcUrl : v.tcUrl.substr(0, pos2);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue