File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -85,6 +85,7 @@ private function saveCache(): void
85
85
*/
86
86
public function deleteCache (): void
87
87
{
88
+ $ this ->cacheUpdated = false ;
88
89
$ this ->cacheHandler ->delete ($ this ->cacheKey );
89
90
}
90
91
Original file line number Diff line number Diff line change 13
13
14
14
namespace CodeIgniter \Commands \Utilities ;
15
15
16
+ use CodeIgniter \Autoloader \FileLocator ;
17
+ use CodeIgniter \Autoloader \FileLocatorCached ;
16
18
use CodeIgniter \CLI \BaseCommand ;
17
19
use CodeIgniter \CLI \CLI ;
18
20
use CodeIgniter \Publisher \Publisher ;
@@ -72,8 +74,9 @@ public function run(array $params)
72
74
73
75
private function clearCache (): void
74
76
{
75
- $ cache = WRITEPATH . 'cache/FileLocatorCache ' ;
76
- $ this ->removeFile ($ cache );
77
+ $ locator = new FileLocatorCached (new FileLocator (service ('autoloader ' )));
78
+ $ locator ->deleteCache ();
79
+ CLI ::write ('Removed FileLocatorCache. ' , 'green ' );
77
80
78
81
$ cache = WRITEPATH . 'cache/FactoriesCache_config ' ;
79
82
$ this ->removeFile ($ cache );
You can’t perform that action at this time.
0 commit comments