Fix syntax bugs
Fix issue #1