diff --git a/src/js/services/pusher/middleware.js b/src/js/services/pusher/middleware.js index 8a66ff5f..680cd398 100755 --- a/src/js/services/pusher/middleware.js +++ b/src/js/services/pusher/middleware.js @@ -78,7 +78,7 @@ const PusherMiddleware = (function(){ connection.username = connection.username.replace(/\W/g, '') socket = new WebSocket( - 'ws://'+state.mopidy.host+':'+state.mopidy.port+'/iris/ws', + 'ws'+(state.mopidy.port === '443' ? 's' : '')+'://'+state.mopidy.host+':'+state.mopidy.port+'/iris/ws', [ connection.clientid, connection.connection_id, connection.username ] ); @@ -316,4 +316,4 @@ const PusherMiddleware = (function(){ })(); -export default PusherMiddleware \ No newline at end of file +export default PusherMiddleware