fixed issue #529
Merge pull request #530 from elanting/master

fixed issue #529