Fixed #42
Merge pull request #48 from ShawnMcCool/magic-fix

Fixed #46