cleanRootFromPath trims the root of the current fs from a path
(p string)
| 1825 | |
| 1826 | // cleanRootFromPath trims the root of the current fs from a path |
| 1827 | func (f *Fs) cleanRootFromPath(p string) string { |
| 1828 | if f.Root() != "" { |
| 1829 | p = p[len(f.Root()):] // trim out root |
| 1830 | if len(p) > 0 { // remove first separator |
| 1831 | p = p[1:] |
| 1832 | } |
| 1833 | } |
| 1834 | |
| 1835 | return p |
| 1836 | } |
| 1837 | |
| 1838 | func (f *Fs) isRootInPath(p string) bool { |
| 1839 | if f.Root() == "" { |