TrimStrings Middleware is not working?

I add the TrimStrings middleware in the middleware method in the config of the panel, but it does not seem to work. I save a form where I put spaces around a field and these spaces are saved in the database.

Anyone has experienced that?

Am I doing something wrong?
Was this page helpful?