minor cleanup for #1475

Cleanup for https://github.com/rapid7/metasploit-framework/pull/1475

Feel free to review, test, and if you agree with changes land it into your repo, the original pull request will be automatically updated :)