Skip to content

Commit

Permalink
fix no image checking
Browse files Browse the repository at this point in the history
  • Loading branch information
RamRamez committed Aug 8, 2023
1 parent 0204b41 commit 9b3e7b6
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/lib/helpers.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,15 @@
import { promisify } from 'util';
// eslint-disable-next-line import/named
import unescape from 'lodash/unescape';

import { parseEther, parseUnits } from '@ethersproject/units';
import { keccak256 } from '@ethersproject/keccak256';
import { Contract } from '@ethersproject/contracts';
import { TransactionResponse, Web3Provider } from '@ethersproject/providers';
import { AddressZero } from '@ethersproject/constants';
import { brandColors } from '@giveth/ui-design-system';
// @ts-ignore
import abi from 'human-standard-token-abi';

import { captureException } from '@sentry/nextjs';
import { brandColors } from '@giveth/ui-design-system';
import { BasicNetworkConfig, GasPreference } from '@/types/config';
import { EWallets } from '@/lib/wallet/walletTypes';
import { giveconomyTabs } from '@/lib/constants/Tabs';
Expand Down Expand Up @@ -225,8 +223,7 @@ export const noImgColor = () => noImgColors[Math.floor(Math.random() * 3)];

export const noImgIcon = '/images/GIV-icon-text.svg';

export const isNoImg = (image: string | undefined) =>
!(image && !Number(image));
export const isNoImg = (image: string | undefined) => !image || image === '';

export const shortenAddress = (
address: string | null | undefined,
Expand Down

0 comments on commit 9b3e7b6

Please sign in to comment.