Fixes issue #18.
Fixes issue #17.