func FindAccountInList(me AccountKey, lst []AccountKey) int {
	for index, user := range lst {
		if user == me {
			return index
		}
	}
	return -1
}
FindAccountInList - find AccountKey in given AccountKey list
package types
import (
	"regexp"
	sdk "github.com/cosmos/cosmos-sdk/types"
)
type AccountKey string
type PoolName string
type Permlink string
type ProposalKey string
type Permission int
type CapacityLevel int
type ProposalResult int
type ProposalType int
type DonationType int
type TransferDetailType int
type PunishType int
type AccOrAddr struct {
	AccountKey AccountKey     `json:"account_key,omitempty"`
	Addr       sdk.AccAddress `json:"addr,omitempty"`
	IsAddr     bool           `json:"is_addr,omitempty"`
}
func NewAccOrAddrFromAcc(acc AccountKey) AccOrAddr {
	return AccOrAddr{
		AccountKey: acc,
	}
}
func NewAccOrAddrFromAddr(addr sdk.AccAddress) AccOrAddr {
	return AccOrAddr{
		Addr:   addr,
		IsAddr: true,
	}
}
func (a AccOrAddr) IsValid() bool {
	if a.IsAddr {
		return sdk.VerifyAddressFormat(a.Addr) == nil
	}
	return a.AccountKey.IsValid()
}
func (a AccOrAddr) String() string {
	if a.IsAddr {
		return a.Addr.String()
	}
	return string(a.AccountKey)
}
func GetPermlink(author AccountKey, postID string) Permlink {
	return Permlink(string(author) + PermlinkSeparator + postID)
}