Blocked:mixed content on Laravel post request when optional route parameter is empty

143 views Asked by At

I have a route defined as follows

Route::post('s3/create/directory/{path?}', [S3Controller::class, 'createDirectory'])
            ->name('s3.create.directory')
            ->where('path', '.*');

It works fine when posting to it, except when the path value is an empty string, then I get a blocked:mixed-content from Chrome.

I have triple checked, and there are no HTTP requests on the page and because I am using InertiaJS, it actually comes from the same page. The only difference is that the path value is an empty string.

Anyone have any ideas?

0

There are 0 answers