bugfix: test options undefined, and assign a default value
add version number