Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check, if cache file exists instead of having config value #124

Open
sergejostir opened this issue Dec 22, 2019 · 0 comments
Open

Check, if cache file exists instead of having config value #124

sergejostir opened this issue Dec 22, 2019 · 0 comments

Comments

@sergejostir
Copy link

Is there an interest to make themes cache work the same way as whole Laravel framework uses for its cache (config, routes, etc)?

Currently this package has a specific config option which controls the cache. The more reasonable way would be to simply check, if cache file exist (like Laravel does for its caches). That way there can't be any de-sync between actual cache state and the config value.
So when you enable cache the cache file is created (ON) and when you disable it, the file is deleted (OFF).

I can make a PR for this. It would be a fully backwards compatibile (themes.cache config value would have a preference over file check), but the config key wouldn't be specified by default anymore, so it can be removed on next major version release.

Considering that this package is made specifically for Laravel, it would make sense to follow common laravel "convention".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant