Do not remove non-slash first character of module

The removal of initial slash in the path was error-prone and always removed first character from the string, even if it's not a slash. I replaced that with a small improvement to the cleaning regex.

Fixes #1106
Merge pull request #1107 from arty-name/patch-2

Do not remove non-slash first character of module