mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2024-12-31 16:21:21 +00:00
Handle empty backtrace parameter gracefully (#448)
Fixes the issue that causes a panic when starting `state` command. ``` > go run ./cmd/state verifySnapshot panic: expect file.go:234 ```
This commit is contained in:
parent
1dcc7661fc
commit
161af5d1c5
@ -141,9 +141,11 @@ func SetupCobra(cmd *cobra.Command) error {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
err = glogger.BacktraceAt(backtrace)
|
||||
if err != nil {
|
||||
return err
|
||||
if backtrace != "" {
|
||||
err = glogger.BacktraceAt(backtrace)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
log.Root().SetHandler(glogger)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user