Fix issue #1
Fix issue #2