More refactoring.
Merge pull request #11 from pedroigor/master

More refactoring.