Closed Jacobtims closed 7 months ago
Fixes #30
Hello there! Here's a simple summation of the changes we've made:
RickDBCN\FilamentEmail\Models\Email
model can be found in your config/filament-email.php
config file. This increases flexibility on how and where this model is utilized across your project.EmailFactory
and EmailResource
classes underwent changes for better functioning! These classes now dynamically pull the Email model from our config file or if not found, they'll rely on our default RickDBCN\FilamentEmail\Models\Email
π.$record
parameter found in EmailResource
class was updated to a generic type. Same for the resend
method!FilamentEmailLogger
class has a new 'model' variable which fetches the model from the config (or defaults to RickDBCN\FilamentEmail\Models\Email
as a failsafe). This plays a key role when creating new instances.$email
parameter in ResendMail
class is now of a generic type β ensuing better adaptability. Plus, the EmailModelTest
file got spicier with a beforeEach
hook to fetch our model. This makes the test cases even smarter!All in all, these changes flex up elements of autonomy and efficiency in our code β ensuring it dances smoothly to the rhythm of your project's needs. Enjoy the updated harmony! πΆπ€©
Looks good to me! Thanks! :)
This pull request makes the Email model configurable via the
config/filament-email.php
config file. This allows users to override the Email model used by the package.