codefog / contao-haste

Haste is a collection of tools and classes to ease working with Contao
http://codefog.pl/extension/haste.html
MIT License
43 stars 24 forks source link

Add compatibility for Contao 5.4+ #225

Closed fritzmg closed 5 days ago

fritzmg commented 6 days ago

Fixes #223

This adds compatibility for Contao 5.4+ by allowing both the deprecated and the new type for the @security.helper service.

qzminski commented 6 days ago

Let me know when it's RTM :)

fritzmg commented 6 days ago

Yeah, sorry, I just noticed this can be fixed even easier by using the interface of the helper service.

qzminski commented 6 days ago

@Toflar can you check this again before I merge?

Toflar commented 6 days ago

I don't know🤷‍♂️

qzminski commented 6 days ago

@fritzmg is it ready to merge then? :)

fritzmg commented 6 days ago

Yes 👍. Tested in 4.13 and 5.x

fritzmg commented 6 days ago

Although I can think of one other improvment that makes the code even more agnostic to the Symfony version 😁

Instead of injecting the security.helper, we could instead inject TokenStorageInterface in the DocrineOrmHelper, since all we want is the user.

qzminski commented 6 days ago

Looks good to me, so if it works, I can finally merge it :)