[VDB-751 VDB-754] Bugfix null pointer panic and improve logging (#119)

* VDB-751 VDB-754 Bugfix null pointer panic and improve logging

* Fix typo
This commit is contained in:
Edvard Hübinette
2019-07-18 09:21:40 +02:00
committed by GitHub
parent af6190ea09
commit 2c092e8d04
7 changed files with 166 additions and 25 deletions
+2 -2
View File
@@ -31,7 +31,7 @@ import (
func LoadPostgres(database config.Database, node core.Node) postgres.DB {
db, err := postgres.NewDB(database, node)
if err != nil {
log.Fatalf("Error loading postgres\n%v", err)
log.Fatal("Error loading postgres: ", err)
}
return *db
}
@@ -65,7 +65,7 @@ func GetAbi(abiFilepath string, contractHash string, network string) string {
}
_, err := geth.ParseAbi(contractAbiString)
if err != nil {
log.Fatalln("Invalid ABI")
log.Fatalln("Invalid ABI: ", err)
}
return contractAbiString
}