mirror of
https://github.com/bettercap/bettercap
synced 2025-08-19 21:13:18 -07:00
misc: small fix or general refactoring i did not bother commenting
This commit is contained in:
parent
ae81bb8606
commit
ea477ef2b4
4 changed files with 38 additions and 45 deletions
|
@ -37,22 +37,22 @@ var PromptCallbacks = map[string]func(s *Session) string{
|
|||
return s.Interface.CIDR()
|
||||
},
|
||||
"{net.sent}": func(s *Session) string {
|
||||
return fmt.Sprintf("%d", s.Queue.Sent)
|
||||
return fmt.Sprintf("%d", s.Queue.Stats.Sent)
|
||||
},
|
||||
"{net.sent.human}": func(s *Session) string {
|
||||
return humanize.Bytes(s.Queue.Sent)
|
||||
return humanize.Bytes(s.Queue.Stats.Sent)
|
||||
},
|
||||
"{net.received}": func(s *Session) string {
|
||||
return fmt.Sprintf("%d", s.Queue.Received)
|
||||
return fmt.Sprintf("%d", s.Queue.Stats.Received)
|
||||
},
|
||||
"{net.received.human}": func(s *Session) string {
|
||||
return humanize.Bytes(s.Queue.Received)
|
||||
return humanize.Bytes(s.Queue.Stats.Received)
|
||||
},
|
||||
"{net.packets}": func(s *Session) string {
|
||||
return fmt.Sprintf("%d", s.Queue.PktReceived)
|
||||
return fmt.Sprintf("%d", s.Queue.Stats.PktReceived)
|
||||
},
|
||||
"{net.errors}": func(s *Session) string {
|
||||
return fmt.Sprintf("%d", s.Queue.Errors)
|
||||
return fmt.Sprintf("%d", s.Queue.Stats.Errors)
|
||||
},
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue