fix(@embark/utils): fix deconstruct url to return port as an integer

(cherry picked from commit e41a1d58c11b9808e8d2827e73ed98bce6d82d22)
This commit is contained in:
Jonathan Rainville 2020-01-08 13:54:13 -05:00 committed by Iuri Matias
parent 9aa9e6cf5a
commit 4190d5ec65
1 changed files with 1 additions and 1 deletions

View File

@ -173,7 +173,7 @@ export function deconstructUrl(endpoint) {
return { return {
protocol: matches[1], protocol: matches[1],
host: matches[2], host: matches[2],
port: matches[3], port: matches[3] ? parseInt(matches[3], 10) : false,
type: matches[1] === 'ws' || matches[1] === 'wss' ? 'ws' : 'rpc' type: matches[1] === 'ws' || matches[1] === 'wss' ? 'ws' : 'rpc'
}; };
} }