mirror of
https://github.com/bettercap/bettercap
synced 2025-07-16 10:03:39 -07:00
more lint driven refactoring
This commit is contained in:
parent
0de6f3a76e
commit
1afab5d7be
7 changed files with 19 additions and 26 deletions
|
@ -58,7 +58,7 @@ func ArpUpdate(iface string) (ArpTable, error) {
|
|||
|
||||
func ArpLookup(iface string, address string, refresh bool) (string, error) {
|
||||
// Refresh ARP table if first run or if a force refresh has been instructed.
|
||||
if ArpParsed() == false || refresh {
|
||||
if !ArpParsed() || refresh {
|
||||
if _, err := ArpUpdate(iface); err != nil {
|
||||
return "", err
|
||||
}
|
||||
|
@ -76,7 +76,7 @@ func ArpLookup(iface string, address string, refresh bool) (string, error) {
|
|||
}
|
||||
|
||||
func ArpInverseLookup(iface string, mac string, refresh bool) (string, error) {
|
||||
if ArpParsed() == false || refresh {
|
||||
if !ArpParsed() || refresh {
|
||||
if _, err := ArpUpdate(iface); err != nil {
|
||||
return "", err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue