Fix some issues reported by scrutinizer-ci
Merge pull request #184 from geekwright/formsfix

Fix some issues reported by scrutinizer-ci