Code update

Includes a fix for issue #8