roots/acorn

Latest changes to Bootloader::registerWordPressRoute() throws Exception

dsturm opened this issue · 0 comments

Version

dev-main

What did you expect to happen?

Site could be opened

What actually happens?

The latest changes from #334 throw an exception for me - even on a clean bedrock / sage project:

Roots\Acorn\Bootloader::Roots\Acorn\{closure}(): Argument #1 ($response) must be of type Illuminate\Http\Response, Illuminate\Routing\ResponseFactory given, called in /sites/acorn-test/vendor/illuminate/support/helpers.php on line 307

since response() will return Illuminate\Routing\ResponseFactory rather than required Illuminate\Http\Response if arguments are omitted.

Further the header_remove() fails because of already sent headers.

Steps to reproduce

  1. Install new roots/bedrock project
  2. Require roots/acorn:dev-main
  3. Install fresh roots/sage or roots/sage:dev-main into theme folder, install dependencies and build theme
  4. Visit front page

System info

No response

Log output

No response

Please confirm this isn't a support request.

Yes