code: protected String stripFileSeparateAtTheEnd(String path) {
          return (path != null && (path.endsWith("/") || path.endsWith("\\") ) ) 
                  ? path.substring(0, path.length()-1)
                  : path;
      }
docs: remove separator at the end of userDir directory if exist
  @param path
  @return