Skip to content

Commit

Permalink
Merge pull request pancakeswap#233 from kogecoin/229-vault-type-and-p…
Browse files Browse the repository at this point in the history
…latform-filters-combination

fix pancakeswap#229
  • Loading branch information
0xRektora committed Oct 3, 2021
2 parents 66a09c4 + ad2b04c commit 675eee1
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/views/Farms/Farms.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ const Farms: React.FC = () => {
)

const farmsList = useCallback(
(farmsToDisplay: Farm[], filterQuery?:boolean): FarmWithStakedValue[] => {
(farmsToDisplay: Farm[], filterQuery?: boolean): FarmWithStakedValue[] => {
let farmsToDisplayWithAPR: FarmWithStakedValue[] = farmsToDisplay.map((farm) => {
/* DZ Hack
if (!farm.lpTotalInQuoteToken || !prices) {
Expand Down Expand Up @@ -643,7 +643,12 @@ const Farms: React.FC = () => {


const handleItemClick = activeIndex => {
setMultiSearch(activeIndex)
const search = multiSearch
if (search.has('platform')) {
setMultiSearch(new Set<any>(activeIndex).add('platform'))
} else {
setMultiSearch(new Set(activeIndex))
}
setIsSearching(!isSearching)
setSortOption('multi')
}
Expand Down

0 comments on commit 675eee1

Please sign in to comment.