Fix deprecation warnings
Merge pull request #44 from hannobraun/master

Fix deprecation warnings