@@ -46,8 +46,7 @@ module.exports = function createServers(options, listening) {
46
46
var handler = options . handler ,
47
47
log = options . log || function ( ) { } ,
48
48
errors = { } ,
49
- servers = { } ,
50
- errState ;
49
+ servers = { } ;
51
50
52
51
//
53
52
// ### function onListen(type, err, server)
@@ -72,7 +71,7 @@ module.exports = function createServers(options, listening) {
72
71
return listening ( errs . create ( {
73
72
message : ( errors . https || errors . http ) . message ,
74
73
https : errors . https ,
75
- http : errors . http ,
74
+ http : errors . http
76
75
} ) , servers ) ;
77
76
}
78
77
@@ -101,12 +100,11 @@ module.exports = function createServers(options, listening) {
101
100
102
101
var server = http . createServer ( options . http . handler || handler ) ,
103
102
port = options . http . port || 80 ,
104
- args ,
105
- ip ;
103
+ args ;
106
104
107
105
args = [ server , port ] ;
108
- if ( ip === options . http . ip ) {
109
- args . push ( ip ) ;
106
+ if ( options . http . host ) {
107
+ args . push ( options . http . host ) ;
110
108
}
111
109
112
110
log ( 'http | try listen ' + port ) ;
@@ -160,7 +158,7 @@ module.exports = function createServers(options, listening) {
160
158
// https://certsimple.com/blog/a-plus-node-js-ssl
161
159
//
162
160
ciphers : ssl . ciphers ,
163
- honorCipherOrder : ssl . honorCipherOrder === false ? false : true ,
161
+ honorCipherOrder : ! ! ssl . honorCipherOrder ,
164
162
//
165
163
// Optionally support SNI-based SSL.
166
164
//
@@ -174,8 +172,8 @@ module.exports = function createServers(options, listening) {
174
172
} , ssl . handler || handler ) ;
175
173
176
174
args = [ server , port ] ;
177
- if ( ip === options . https . ip ) {
178
- args . push ( ip ) ;
175
+ if ( options . https . host ) {
176
+ args . push ( options . https . host ) ;
179
177
}
180
178
181
179
args . push ( function listener ( err ) { onListen ( 'https' , err , this ) ; } ) ;
0 commit comments