From d618cce6f1caf284ae5fa1eba486b9dd2120aba4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Muhammed=20Tanr=C4=B1kulu?= Date: Tue, 24 Sep 2024 01:41:23 +0200 Subject: [PATCH] lint --- src/utils/isImageURI.ts | 4 ++-- test/resolver.test.ts | 1 - test/utils.test.ts | 9 +++++++-- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/src/utils/isImageURI.ts b/src/utils/isImageURI.ts index 98a8eca..b20c777 100644 --- a/src/utils/isImageURI.ts +++ b/src/utils/isImageURI.ts @@ -18,11 +18,11 @@ export const ALLOWED_IMAGE_MIMETYPES = [ ]; export const IMAGE_SIGNATURES = { - 'FFD8FF': 'image/jpeg', + FFD8FF: 'image/jpeg', '89504E47': 'image/png', '47494638': 'image/gif', '424D': 'image/bmp', - 'FF0A': 'image/jxl', + FF0A: 'image/jxl', }; const MAX_FILE_SIZE = 300 * 1024 * 1024; // 300 MB diff --git a/test/resolver.test.ts b/test/resolver.test.ts index ca5bdde..688124c 100644 --- a/test/resolver.test.ts +++ b/test/resolver.test.ts @@ -608,7 +608,6 @@ describe('get banner/header', () => { ] ); - const HEADER_URI_TANRIKULU = new URL( 'https://ipfs.io/ipfs/QmUShgfoZQSHK3TQyuTfUpsc8UfeNfD8KwPUvDBUdZ4nmR' ); diff --git a/test/utils.test.ts b/test/utils.test.ts index 7cd92b4..da9d916 100644 --- a/test/utils.test.ts +++ b/test/utils.test.ts @@ -61,7 +61,9 @@ describe('resolve ipfs', () => { it('resolve different ipfs uri cases with custom gateway', () => { for (let uri of ipfsCases) { - const { uri: resolvedURI } = resolveURI(uri, { ipfs: 'https://custom-ipfs.io' }); + const { uri: resolvedURI } = resolveURI(uri, { + ipfs: 'https://custom-ipfs.io', + }); expect(resolvedURI).toMatch(/^https:\/\/custom-ipfs.io\/?/); } }); @@ -321,7 +323,10 @@ describe('getImageURI', () => { it('should handle errors in base64 decoding', () => { const invalidBase64 = 'data:image/svg+xml;base64,Invalid Base64!!!'; - const result = getImageURI({ metadata: { image: invalidBase64 }, jsdomWindow }); + const result = getImageURI({ + metadata: { image: invalidBase64 }, + jsdomWindow, + }); expect(result).toBeNull(); });