fix bug
Merge pull request #12 from cliviu/objectfactory

fix bug