laravisit
laravisit copied to clipboard
scopePopularAllTime and scopePopularBetween modification
- Inside the scopePopularAllTime() I added a whereHas('visits) to only fetch records that has been visited, initially it was returning all records including those without visits.
- Inside the scopePopularBetween(), I added an orderBy clause to get the records in descending order starting with that with the highest visit count. This is helpful in case the user only needs one result that has highest visit count.
Hello, @mainadennis
Sorry for the late response.
It seems some tests failed, can you run the tests in your end, and see what's wrong exactly!
Thanks for your time/PR.
Hello @ousid The tests seems to be failing due to a composer plugin not from the pull request, here's a message from all the failing tests "Error: pestphp/pest-plugin contains a Composer plugin which is blocked by your allow-plugins config. You may add it to the list if you consider it safe."
Hey, @mainadennis.
The codebase has been update, consider to pull the latest changes, and try again.
Thanks!