Trim only the separator key at end of path to allow keys ending with '.'

Basically allow
```js
t("Loading...");
```
when having separator e.g. `::`. Before this pull request it would trim one '.' char.