Check error

This commit is contained in:
Christopher Goes
2018-11-14 18:23:20 -08:00
committed by Jack Zampolin
parent 17b9afaaa7
commit 42402d3f97
2 changed files with 6 additions and 3 deletions
+2 -2
View File
@@ -325,8 +325,8 @@ func (app *GaiaApp) ExportAppStateAndValidators() (appState json.RawMessage, val
}
// load a particular height
func (app *GaiaApp) LoadHeight(height int64) {
app.LoadVersion(height, app.keyMain)
func (app *GaiaApp) LoadHeight(height int64) error {
return app.LoadVersion(height, app.keyMain)
}
//______________________________________________________________________________________________
+4 -1
View File
@@ -68,7 +68,10 @@ func exportAppStateAndTMValidators(
) (json.RawMessage, []tmtypes.GenesisValidator, error) {
gApp := app.NewGaiaApp(logger, db, traceStore)
if height != -1 {
gApp.LoadHeight(height)
err := gApp.LoadHeight(height)
if err != nil {
return err
}
}
return gApp.ExportAppStateAndValidators()
}