github.com/lino-network/lino@v0.6.11/x/bandwidth/model/errors.go (about) 1 package model 2 3 import ( 4 "fmt" 5 6 "github.com/lino-network/lino/types" 7 8 sdk "github.com/cosmos/cosmos-sdk/types" 9 ) 10 11 // ErrBandwidthInfoNotFound - error if bandwidth info is not found 12 func ErrBandwidthInfoNotFound() sdk.Error { 13 return types.NewError(types.CodeBandwidthInfoNotFound, fmt.Sprintf("bandwidth info is not found")) 14 } 15 16 // ErrBlockInfoNotFound - error if last block info is not found 17 func ErrBlockInfoNotFound() sdk.Error { 18 return types.NewError(types.CodeBlockInfoNotFound, fmt.Sprintf("block info is not found")) 19 } 20 21 // ErrAppBandwidthInfoNotFound - error if app bandwidth info is not found 22 func ErrAppBandwidthInfoNotFound() sdk.Error { 23 return types.NewError(types.CodeAppBandwidthInfoNotFound, fmt.Sprintf("app bandwidth info is not found")) 24 }