fix #30 Tolerate 'undefined' in constructor

 On branch master

	modified:   index.js
	modified:   test/base_test.js