Merge pull request #168 from josemduarte/master

Solving issue #160
Solving issue #145