mirror of
https://github.com/bettercap/bettercap
synced 2025-07-07 13:32:07 -07:00
refact: refactored to use islazy and updated deps
This commit is contained in:
parent
a2b3ee79fb
commit
d070445225
238 changed files with 12662 additions and 1586 deletions
|
@ -8,7 +8,7 @@ import (
|
|||
"strconv"
|
||||
"sync"
|
||||
|
||||
"github.com/bettercap/bettercap/core"
|
||||
"github.com/evilsocket/islazy/fs"
|
||||
)
|
||||
|
||||
type EnvironmentChangedCallback func(newValue string)
|
||||
|
@ -26,8 +26,8 @@ func NewEnvironment(envFile string) (*Environment, error) {
|
|||
}
|
||||
|
||||
if envFile != "" {
|
||||
envFile, _ := core.ExpandPath(envFile)
|
||||
if core.Exists(envFile) {
|
||||
envFile, _ := fs.Expand(envFile)
|
||||
if fs.Exists(envFile) {
|
||||
if err := env.Load(envFile); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue