Skip to content

Commit 16d451a

Browse files
committed
chore: Fixed code styles.
1 parent e495754 commit 16d451a

File tree

2 files changed

+19
-20
lines changed

2 files changed

+19
-20
lines changed

src/__tests__/uploadcare-loader.spec.ts

Lines changed: 15 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,11 @@ describe('uploadcareLoader', () => {
1212

1313
const src = '/relative/image.jpg';
1414

15-
const result =
16-
uploadcareLoader({
17-
src,
18-
width: 0,
19-
quality: 80
20-
});
15+
const result = uploadcareLoader({
16+
src,
17+
width: 0,
18+
quality: 80
19+
});
2120

2221
expect(result).toEqual(src);
2322

@@ -32,12 +31,11 @@ describe('uploadcareLoader', () => {
3231

3332
const src = '/relative/image.jpg';
3433

35-
let result =
36-
uploadcareLoader({
37-
src,
38-
width: 0,
39-
quality: 80
40-
});
34+
let result = uploadcareLoader({
35+
src,
36+
width: 0,
37+
quality: 80
38+
});
4139

4240
expect(result).toEqual(src);
4341

@@ -46,12 +44,11 @@ describe('uploadcareLoader', () => {
4644
const basePath = 'https://example.com';
4745
addEnvVar('NEXT_PUBLIC_UPLOADCARE_APP_BASE_PATH', basePath);
4846

49-
result =
50-
uploadcareLoader({
51-
src,
52-
width: 0,
53-
quality: 80
54-
});
47+
result = uploadcareLoader({
48+
src,
49+
width: 0,
50+
quality: 80
51+
});
5552

5653
expect(result).toEqual(`${basePath}${src}`);
5754

src/utils/loader.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,9 @@ export function uploadcareLoader({
3838
const proxyEndpoint =
3939
customProxyEndpoint || generateDefaultProxyEndpoint(publicKey);
4040

41-
const basePath = trimTrailingSlash(process.env.NEXT_PUBLIC_UPLOADCARE_APP_BASE_PATH || '');
41+
const basePath = trimTrailingSlash(
42+
process.env.NEXT_PUBLIC_UPLOADCARE_APP_BASE_PATH || ''
43+
);
4244

4345
const proxy = trimTrailingSlash(proxyEndpoint);
4446

@@ -66,7 +68,7 @@ export function uploadcareLoader({
6668
if (!isBasePathSet) {
6769
return src;
6870
}
69-
71+
7072
return `${basePath}${src}`;
7173
}
7274

0 commit comments

Comments
 (0)