Fixing trailing slash bug.

Should detect if user uses a trailing slash in the host
argument and handle it gracefully.
Merge pull request #19 from sag47/bug-trailing-slash

Fixing trailing slash bug.