(path string)
| 43 | } |
| 44 | |
| 45 | func (d *Alias) getRootAndPath(path string) (string, string) { |
| 46 | if d.autoFlatten { |
| 47 | return d.oneKey, path |
| 48 | } |
| 49 | path = strings.TrimPrefix(path, "/") |
| 50 | parts := strings.SplitN(path, "/", 2) |
| 51 | if len(parts) == 1 { |
| 52 | return parts[0], "" |
| 53 | } |
| 54 | return parts[0], parts[1] |
| 55 | } |
| 56 | |
| 57 | func (d *Alias) get(ctx context.Context, path string, dst, sub string) (model.Obj, error) { |
| 58 | obj, err := fs.Get(ctx, stdpath.Join(dst, sub), &fs.GetArgs{NoLog: true}) |
no outgoing calls
no test coverage detected