Skip to content

Commit 8a9c7c2

Browse files
committed
revert: commit a0d1856 that changed the bootloader.
The `config()` method of `Application` doesn't exist in the current Acorn (v4.3.1) and this new bootloader code is not apart of Sage v10.8.2, but for an upcoming version of Sage. Fixes PHP error: "Fatal error: Uncaught BadMethodCallException: Method Roots\Acorn\Application::configure does not exist." by reverting the code changed in commit a0d1856.
1 parent 8bb6952 commit 8a9c7c2

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

functions.php

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
<?php
22

3-
use Roots\Acorn\Application;
4-
53
/*
64
|--------------------------------------------------------------------------
75
| Register The Auto Loader
@@ -31,11 +29,18 @@
3129
|
3230
*/
3331

34-
Application::configure()
35-
->withProviders([
36-
App\Providers\ThemeServiceProvider::class,
37-
])
38-
->boot();
32+
if (! function_exists('\Roots\bootloader')) {
33+
wp_die(
34+
__('You need to install Acorn to use this theme.', 'sage'),
35+
'',
36+
[
37+
'link_url' => 'https://roots.io/acorn/docs/installation/',
38+
'link_text' => __('Acorn Docs: Installation', 'sage'),
39+
]
40+
);
41+
}
42+
43+
\Roots\bootloader()->boot();
3944

4045
/*
4146
|--------------------------------------------------------------------------

0 commit comments

Comments
 (0)