nova-menu icon indicating copy to clipboard operation
nova-menu copied to clipboard

Menu filter does not show when running on Octane

Open webard opened this issue 2 years ago • 2 comments

Hi,

when app is running on Octane with Swoole (I did not tested RR or Franken), MenuFilter::activate needs to be run on every request, not only in Service Provider, which are ran only once at first request.

Solution is class:

namespace App\Octane;

use NormanHuth\NovaMenu\Services\MenuFilter;

class ActivateMenuFilter
{

    public function handle()
    {
        MenuFilter::activate('top');
    }
}

and modification in octane.php:

use App\Octane\ActivateMenuFilter;
...
'listeners' => [
 ...
        RequestReceived::class => [
            ...
            ActivateMenuFilter::class,
        ],
]

webard avatar Feb 08 '24 20:02 webard

I'll have to have a look first. I don't have any contact with Octane and didn't intend to until now.

Muetze42 avatar Feb 09 '24 16:02 Muetze42

@Muetze42 created a reference to a task for the project „nova-menu“:
https://todos.huth.it/9b5bc3f5-e7d1-4e28-96e0-1abf8701912d

maria42-bot avatar Feb 17 '24 15:02 maria42-bot