refact: update the source code to avoid the deprecated method calls.
Merge pull request #1 from fraisse/master

A little cleanup