Fix #421 and Fix #419
Merge pull request #422 from antgonza/issue_421

Fix #421 and Fix #419