Browse Source

go fmt

pull/914/head
Chris Lu 6 years ago
parent
commit
78ac2bef3c
  1. 6
      weed/server/filer_grpc_server_rename.go
  2. 2
      weed/shell/command_fs_tree.go

6
weed/server/filer_grpc_server_rename.go

@ -38,7 +38,7 @@ func (fs *FilerServer) AtomicRenameEntry(ctx context.Context, req *filer_pb.Atom
return &filer_pb.AtomicRenameEntryResponse{}, nil return &filer_pb.AtomicRenameEntryResponse{}, nil
} }
func (fs *FilerServer) moveEntry(ctx context.Context, oldParent filer2.FullPath, entry *filer2.Entry, newParent filer2.FullPath, newName string) (error) {
func (fs *FilerServer) moveEntry(ctx context.Context, oldParent filer2.FullPath, entry *filer2.Entry, newParent filer2.FullPath, newName string) error {
if entry.IsDirectory() { if entry.IsDirectory() {
if err := fs.moveFolderSubEntries(ctx, oldParent, entry, newParent, newName); err != nil { if err := fs.moveFolderSubEntries(ctx, oldParent, entry, newParent, newName); err != nil {
return err return err
@ -47,7 +47,7 @@ func (fs *FilerServer) moveEntry(ctx context.Context, oldParent filer2.FullPath,
return fs.moveSelfEntry(ctx, oldParent, entry, newParent, newName) return fs.moveSelfEntry(ctx, oldParent, entry, newParent, newName)
} }
func (fs *FilerServer) moveFolderSubEntries(ctx context.Context, oldParent filer2.FullPath, entry *filer2.Entry, newParent filer2.FullPath, newName string) (error) {
func (fs *FilerServer) moveFolderSubEntries(ctx context.Context, oldParent filer2.FullPath, entry *filer2.Entry, newParent filer2.FullPath, newName string) error {
currentDirPath := oldParent.Child(entry.Name()) currentDirPath := oldParent.Child(entry.Name())
newDirPath := newParent.Child(newName) newDirPath := newParent.Child(newName)
@ -80,7 +80,7 @@ func (fs *FilerServer) moveFolderSubEntries(ctx context.Context, oldParent filer
return nil return nil
} }
func (fs *FilerServer) moveSelfEntry(ctx context.Context, oldParent filer2.FullPath, entry *filer2.Entry, newParent filer2.FullPath, newName string) (error) {
func (fs *FilerServer) moveSelfEntry(ctx context.Context, oldParent filer2.FullPath, entry *filer2.Entry, newParent filer2.FullPath, newName string) error {
oldPath, newPath := oldParent.Child(entry.Name()), newParent.Child(newName) oldPath, newPath := oldParent.Child(entry.Name()), newParent.Child(newName)

2
weed/shell/command_fs_tree.go

@ -124,7 +124,7 @@ func (p *Prefix) getPrefix(level int, isLastChild bool) string {
} }
if isLastChild { if isLastChild {
sb.WriteString("└──") sb.WriteString("└──")
p.removeMarker(level);
p.removeMarker(level)
} else { } else {
sb.WriteString("├──") sb.WriteString("├──")
} }

Loading…
Cancel
Save