mirror of
				https://github.com/therootcompany/greenlock-express.js.git
				synced 2024-11-16 17:28:59 +00:00 
			
		
		
		
	Merge pull request #23 from Farbdose/patch-1
printing primitive arrays in opts in one line
This commit is contained in:
		
						commit
						16e458c561
					
				@ -19,8 +19,13 @@ module.exports.create = function (opts) {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  if (!opts) { throw new Error("requires opts to be an object"); }
 | 
					  if (!opts) { throw new Error("requires opts to be an object"); }
 | 
				
			||||||
  if (opts.debug) {
 | 
					  if (opts.debug) {
 | 
				
			||||||
    console.debug("[LEX] creating sniCallback", JSON.stringify(opts, null, '  '));
 | 
					    console.debug("[LEX] creating sniCallback", JSON.stringify(opts, function(k,v){
 | 
				
			||||||
 | 
					      if(v instanceof Array)
 | 
				
			||||||
 | 
					         return JSON.stringify(v);
 | 
				
			||||||
 | 
					      return v;
 | 
				
			||||||
 | 
					    },'  '));
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					  
 | 
				
			||||||
  if (!opts.letsencrypt) { throw new Error("requires opts.letsencrypt to be a letsencrypt instance"); }
 | 
					  if (!opts.letsencrypt) { throw new Error("requires opts.letsencrypt to be a letsencrypt instance"); }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  if (!opts.lifetime) { opts.lifetime = 90 * 24 * 60 * 60 * 1000; }
 | 
					  if (!opts.lifetime) { opts.lifetime = 90 * 24 * 60 * 60 * 1000; }
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user