AscendingCreations / AxumSession

Axum Session Management Libraries that use Sqlx
MIT License
142 stars 29 forks source link

add Debug and Clone derive to AxumNullPool #27

Closed tadic-luka closed 1 year ago

tadic-luka commented 1 year ago

In the examples, it is shown that we can use AxumNullPool to avoid using DB (useful for unit tests). But based on the docs/source code AxumSessionStore requires that the client T: AxumDatabasePool + Clone + Debug + Sync + Send + 'static The issue is that AxumNullPool is neither Clone nor Debug. So example with AxumNullPool actually does not work, I also tried it in on my own. There is no reason for AxumNullPool not to be Clone and or Debug

This is simple fix by adding derive with Clone and Debug