Fix for compatibility with requests-2.3.0
Fixes #38