RomanStruk / manticore-scout-engine

Manticore Engine for Laravel Scout
Other
36 stars 3 forks source link

[Bug] Cannot make non static method Illuminate\Database\Grammar::escape() static in class RomanStruk\ManticoreScoutEngine\Mysql\ManticoreGrammar #30

Closed degecko closed 1 year ago

degecko commented 1 year ago

Hello,

Today I've updated my composer dependecies and I've noticed an error with this project which I can't really figure out how to solve. I'm using the latest version of Laravel.

Cannot make non static method Illuminate\Database\Grammar::escape() static in class RomanStruk\ManticoreScoutEngine\Mysql\ManticoreGrammar

It's referencing the following line:

vendor/romanstruk/manticore-scout-engine/src/Mysql/ManticoreGrammar.php:488

It seems like the escape method is defined without "static" in the illuminate/database project, so I'm not sure how it end up with static in this project.

I haven't noticed any other but reports regarding this issue, so maybe it's an issue on my end?!

Hopefully somebody here can point me in the right direction.

Thank you!

degecko commented 1 year ago

@RomanStruk I had a little more time to look into this and it seems that laravel/framework/src/Illuminate/Database/Grammar.php introduced a function called escape, like yours, but not static. Bad luck. I think you might need to rename that function to something else.

https://github.com/laravel/framework/blob/10.x/src/Illuminate/Database/Grammar.php#L213