Skip to content

Commit 1bedbd9

Browse files
replace warmsUpCache -> warmUpCache
1 parent 557dcb4 commit 1bedbd9

File tree

5 files changed

+13
-13
lines changed

5 files changed

+13
-13
lines changed

Async/ResolveCacheProcessor.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public function process(Message $psrMessage, Context $psrContext)
5959
$results = [];
6060

6161
foreach ($filters as $filter) {
62-
$this->filterService->warmsUpCache($path, $filter, null, $message->isForce());
62+
$this->filterService->warmUpCache($path, $filter, null, $message->isForce());
6363

6464
$results[$filter] = $this->filterService->getUrlOfFilteredImage($path, $filter);
6565
}

Command/ResolveCacheCommand.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ private function runCacheImageResolve(string $image, string $filter, bool $force
111111
$this->io->group($image, $filter, 'blue');
112112

113113
try {
114-
if ($this->filterService->warmsUpCache($image, $filter, null, $forced)) {
114+
if ($this->filterService->warmUpCache($image, $filter, null, $forced)) {
115115
$this->io->status('resolved', 'green');
116116
} else {
117117
$this->io->status('cached', 'white');

Service/FilterService.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ public function bustCache($path, $filter)
9393
*
9494
* @return bool Returns true if the cache is warmed up
9595
*/
96-
public function warmsUpCache(
96+
public function warmUpCache(
9797
string $path,
9898
string $filter,
9999
?string $resolver = null,
@@ -102,7 +102,7 @@ public function warmsUpCache(
102102
$warmedUp = false;
103103

104104
foreach ($this->buildFilterPathContainers($path) as $filterPathContainer) {
105-
if ($this->warmsUpCacheFilterPathContainer($filterPathContainer, $filter, $resolver, $forced)) {
105+
if ($this->warmUpCacheFilterPathContainer($filterPathContainer, $filter, $resolver, $forced)) {
106106
$warmedUp = true;
107107
}
108108
}
@@ -120,7 +120,7 @@ public function warmsUpCache(
120120
public function getUrlOfFilteredImage($path, $filter, $resolver = null, bool $webpSupported = false)
121121
{
122122
foreach ($this->buildFilterPathContainers($path) as $filterPathContainer) {
123-
$this->warmsUpCacheFilterPathContainer($filterPathContainer, $filter, $resolver);
123+
$this->warmUpCacheFilterPathContainer($filterPathContainer, $filter, $resolver);
124124
}
125125

126126
return $this->resolveFilterPathContainer(new FilterPathContainer($path), $filter, $resolver, $webpSupported);
@@ -146,7 +146,7 @@ public function getUrlOfFilteredImageWithRuntimeFilters(
146146
];
147147

148148
foreach ($this->buildFilterPathContainers($path, $runtimePath, $runtimeOptions) as $filterPathContainer) {
149-
$this->warmsUpCacheFilterPathContainer($filterPathContainer, $filter, $resolver);
149+
$this->warmUpCacheFilterPathContainer($filterPathContainer, $filter, $resolver);
150150
}
151151

152152
return $this->resolveFilterPathContainer(
@@ -194,7 +194,7 @@ private function resolveFilterPathContainer(
194194
*
195195
* @return bool Returns true if the cache is warmed up
196196
*/
197-
private function warmsUpCacheFilterPathContainer(
197+
private function warmUpCacheFilterPathContainer(
198198
FilterPathContainer $filterPathContainer,
199199
string $filter,
200200
?string $resolver = null,

Tests/Async/ResolveCacheProcessorTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ public function testShouldBurstCacheWhenResolvingForced(): void
309309
$filterServiceMock = $this->createFilterServiceMock();
310310
$filterServiceMock
311311
->expects($this->once())
312-
->method('warmsUpCache')
312+
->method('warmUpCache')
313313
->with($imagePath, $filterName, null, $force);
314314

315315
$processor = new ResolveCacheProcessor(

Tests/Service/FilterServiceTest.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ public function testWarmsUpCache(bool $webpGenerate): void
168168
->expects($this->never())
169169
->method('applyFilter');
170170

171-
$this->assertFalse($service->warmsUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver));
171+
$this->assertFalse($service->warmUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver));
172172
}
173173

174174
/**
@@ -214,7 +214,7 @@ public function testWarmsUpCacheForced(bool $webpGenerate): void
214214
)
215215
->willReturn($binary);
216216

217-
$this->assertTrue($service->warmsUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver, true));
217+
$this->assertTrue($service->warmUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver, true));
218218
}
219219

220220
/**
@@ -265,7 +265,7 @@ public function testWarmsUpCacheNotStored(bool $webpGenerate): void
265265
)
266266
->willReturn($binary);
267267

268-
$this->assertTrue($service->warmsUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver));
268+
$this->assertTrue($service->warmUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver));
269269
}
270270

271271
/**
@@ -311,7 +311,7 @@ public function testWarmsUpCacheNotStoredForced(bool $webpGenerate): void
311311
)
312312
->willReturn($binary);
313313

314-
$this->assertTrue($service->warmsUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver, true));
314+
$this->assertTrue($service->warmUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver, true));
315315
}
316316

317317
/**
@@ -356,7 +356,7 @@ public function testWarmsUpCacheNonExistingFilter(bool $webpGenerate): void
356356
$exception->getMessage()
357357
));
358358

359-
$service->warmsUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver, true);
359+
$service->warmUpCache(self::SOURCE_IMAGE, self::FILTER, $resolver, true);
360360
}
361361

362362
/**

0 commit comments

Comments
 (0)