Fixed #247
Merge pull request #842 from dvvrd/fix247

Fixed #247