feat(supertournaments-logo-fix): add condition for extension logo for supertournaments

pull/265/head
andreidekterev 2 years ago
parent 01786d947a
commit 1edd818afd
  1. 6
      src/helpers/getProfileLogo/index.tsx

@ -15,4 +15,8 @@ export const getProfileLogo = ({
id,
profileType,
sportType,
}: GetLogoArgs) => `${URL_AWS}/media/${PROFILE_NAMES[profileType]}/${sportType}/${id}/${profileType === ProfileTypes.PLAYERS ? 'photo.png' : 'logo.png'}`
}: GetLogoArgs) => {
const extension = ProfileTypes.SUPERTOURNAMENTS === profileType ? 'jpg' : 'png'
return `${URL_AWS}/media/${PROFILE_NAMES[profileType]}/${sportType}/${id}/${profileType === ProfileTypes.PLAYERS ? `photo.${extension}` : `logo.${extension}`}`
}

Loading…
Cancel
Save