Note: I have fixed this mistake (replacing ``resone`` by ``reason``) when integrating the pull request.