-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #297 from ergolabs/dev
Release v1.0.4
- Loading branch information
Showing
27 changed files
with
517 additions
and
694 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,13 @@ | ||
import { AmmPool, PoolId } from '@ergolabs/ergo-dex-sdk'; | ||
import { PoolId } from '@ergolabs/ergo-dex-sdk'; | ||
|
||
import { useNetworkPools } from './useNetworkPools'; | ||
import { AmmPool } from '../common/models/AmmPool'; | ||
// import { useNetworkPools } from './useNetworkPools'; | ||
import { useGetAllPools } from './useGetAllPools'; | ||
|
||
const usePosition = (poolId: PoolId): AmmPool | undefined => { | ||
const positions = useNetworkPools(); | ||
return positions?.find((position) => position.id === poolId); | ||
const positions = useGetAllPools(); | ||
const pl = positions?.find((position) => position.id === poolId); | ||
return pl ? new AmmPool(pl) : undefined; | ||
}; | ||
|
||
export { usePosition }; |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.