Skip to content

Commit

Permalink
chore: fix some function names in comment (#1038)
Browse files Browse the repository at this point in the history
Signed-off-by: hanghuge <cmoman@outlook.com>
  • Loading branch information
hanghuge authored Dec 7, 2024
1 parent a9e8d90 commit ccf272a
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion x/leveragelp/keeper/pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ func (k Keeper) RemovePool(ctx sdk.Context, index uint64) {
store.Delete(types.PoolKey(index))
}

// GetAllPool returns all pool
// GetAllPools returns all pool
func (k Keeper) GetAllPools(ctx sdk.Context) (list []types.Pool) {
store := prefix.NewStore(runtime.KVStoreAdapter(k.storeService.OpenKVStore(ctx)), types.KeyPrefix(types.PoolKeyPrefix))
iterator := storetypes.KVStorePrefixIterator(store, []byte{})
Expand Down
2 changes: 1 addition & 1 deletion x/perpetual/keeper/pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func (k Keeper) SetPool(ctx sdk.Context, pool types.Pool) {
store.Set(key, b)
}

// GetAllPool returns all pool
// GetAllPools returns all pool
func (k Keeper) GetAllPools(ctx sdk.Context) (list []types.Pool) {
store := runtime.KVStoreAdapter(k.storeService.OpenKVStore(ctx))
iterator := storetypes.KVStorePrefixIterator(store, types.PoolKeyPrefix)
Expand Down
2 changes: 1 addition & 1 deletion x/perpetual/types/calc_funding_rate.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
sdkmath "cosmossdk.io/math"
)

// CalculateFundingRate calculates and returns the funding rate based on long and short amounts
// CalcFundingRate calculates and returns the funding rate based on long and short amounts
func CalcFundingRate(longAmount, shortAmount sdkmath.Int, baseRate, maxRate, minRate sdkmath.LegacyDec) sdkmath.LegacyDec {
var ratio sdkmath.LegacyDec

Expand Down
2 changes: 1 addition & 1 deletion x/tradeshield/keeper/pending_spot_order.go
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ func (k Keeper) DeleteAllPendingSpotOrder(ctx sdk.Context) (list []types.SpotOrd
return
}

// ExecuteStopLossSpotOrder executes a stop loss order
// ExecuteStopLossOrder executes a stop loss order
func (k Keeper) ExecuteStopLossOrder(ctx sdk.Context, order types.SpotOrder) (*ammtypes.MsgSwapByDenomResponse, error) {
marketPrice, err := k.GetAssetPriceFromDenomInToDenomOut(ctx, order.OrderPrice.BaseDenom, order.OrderPrice.QuoteDenom)
if err != nil {
Expand Down

0 comments on commit ccf272a

Please sign in to comment.