Merge pull request #503 from alexyazvinsky/def-fix