From faa713aa9e6ce5cfe70be9c42656c85dae6a2d9e Mon Sep 17 00:00:00 2001 From: Le Dien Phuc Date: Wed, 5 Jun 2024 16:45:47 +0700 Subject: [PATCH] fix: remove krystal earn section (#1689) --- src/commands/profile/index/processor.ts | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/commands/profile/index/processor.ts b/src/commands/profile/index/processor.ts index a226c5d67..2aa2ada40 100644 --- a/src/commands/profile/index/processor.ts +++ b/src/commands/profile/index/processor.ts @@ -45,8 +45,6 @@ import config from "adapters/config" import { formatVaults } from "commands/vault/list/processor" import { getSlashCommand } from "utils/commands" import { chunk } from "lodash" -import mochiPay from "adapters/mochi-pay" -import { composeInvestPortfolio } from "commands/invest/portfolio/processor" import api from "../../../api" import mochiApi from "../../../adapters/mochi-api" @@ -130,7 +128,6 @@ async function compose( walletsRes, socials, balances, - investPortResp, paginationRes, ] = await Promise.all([ profile.getUserProfile(i.guildId ?? "", dataProfile.id), @@ -138,7 +135,6 @@ async function compose( profile.getUserWallets(target.id, false), profile.getUserSocials(target.id), getBalances(dataProfile.id, target.id, BalanceType.Offchain, i, "", ""), - mochiPay.getKrystalEarnPortfolio({ profile_id: dataProfile.id }), profile.getUserActivities(dataProfile.id, { actions: ["9", "10"], status: "new", @@ -154,9 +150,6 @@ async function compose( vaults = vaultsRes.filter((v) => v.discord_guild?.name).slice(0, 5) } - // Get first 5 invest portfolios - const investPortfolios = investPortResp.data?.slice(0, 5) ?? [] - const { onchainTotal, cexTotal, @@ -257,15 +250,6 @@ async function compose( }), ].join("\n"), }).addFields([ - ...(investPortfolios.length - ? [ - { - name: "Invest Portfolios", - value: composeInvestPortfolio(investPortfolios), - inline: false, - }, - ] - : []), ...(vaults.length ? [ {