Skip to content

Commit

Permalink
fix: wlv not using formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
tuanddd committed Aug 22, 2023
1 parent 35c89b9 commit a679134
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 8 deletions.
1 change: 1 addition & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@

npx lint-staged
yarn generate:types && git add src/types/api.ts
yarn format
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
"lint:fix": "eslint --fix --ext .js,.jsx,.ts .",
"prepare": "husky install",
"generate:types": "node ./scripts/generate-types.js",
"guilds:prune": "node ./scripts/leave-server.js"
"guilds:prune": "node ./scripts/leave-server.js",
"format": "npx prettier src/** --write"
},
"devDependencies": {
"@babel/preset-typescript": "^7.15.0",
Expand Down
2 changes: 1 addition & 1 deletion src/adapters/community.ts
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ class Community extends Fetcher {
public async getFeedbackList(
discordId?: string,
page = 0,
profileId?: string,
profileId?: string
) {
return await this.jsonFetch<{ data: ResponseUserFeedbackResponse }>(
`${API_BASE_URL}/community/feedback`,
Expand Down
2 changes: 1 addition & 1 deletion src/commands/vault/list/processor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ export async function runVaultList(interaction: CommandInteraction) {
new MessageSelectMenu()
.setPlaceholder("💰 View a vault")
.setCustomId("view_vault")
.addOptions(options),
.addOptions(options)
),
]

Expand Down
10 changes: 5 additions & 5 deletions src/commands/watchlist/view/processor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ import CacheManager from "cache/node-cache"
import community from "adapters/community"
import { getSlashCommand } from "utils/commands"
import { ResponseGetWatchlistResponse } from "types/api"
import { formatPercentDigit, formatUsdDigit } from "utils/defi"
import { VERTICAL_BAR } from "utils/constants"
import { groupBy } from "lodash"
import { getProfileIdByDiscord } from "../../../utils/profile"
import { utils } from "@consolelabs/mochi-formatter"
import { VERTICAL_BAR } from "utils/constants"
import { renderChart } from "./chart"
import { paginationButtons } from "utils/router"
import { getProfileIdByDiscord } from "../../../utils/profile"

export function buildSwitchViewActionRow(currentView: string) {
const tokenButton = new MessageButton({
Expand Down Expand Up @@ -133,8 +133,8 @@ export async function composeWatchlist(
const priceChange = t.price_change_percentage_24h ?? 0
return {
symbol: (t.symbol ?? "").toUpperCase(),
priceChange: `${formatPercentDigit(String(priceChange))}%`,
usd: `$${formatUsdDigit(String(price))}`,
priceChange: utils.formatPercentDigit(priceChange),
usd: utils.formatUsdDigit(price),
}
}),
{
Expand Down

0 comments on commit a679134

Please sign in to comment.