fix #339
Merge pull request #355 from Justineo/3.1.0-dev

fix #339