adding support for multiple values and hasmanythrough relation, lacking proper documentation and comments