Fixed #220  & mapper-generator improvements