Skip to content

Commit 10bd315

Browse files
aarondfrancisclaude
andcommitted
Make callPaginator public for closure scope access
The closure is bound to Eloquent Builder, so it cannot access protected methods on FastPaginate. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent d855a94 commit 10bd315

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/FastPaginate.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,10 @@ class FastPaginate
1414
/**
1515
* Laravel 11+ added a $total parameter to paginate(). We need to
1616
* conditionally pass it to avoid errors on Laravel 10.
17+
*
18+
* @internal
1719
*/
18-
protected static function callPaginator($builder, string $method, $perPage, $columns, $pageName, $page, $total)
20+
public static function callPaginator($builder, string $method, $perPage, $columns, $pageName, $page, $total)
1921
{
2022
if (version_compare(app()->version(), '11.0.0', '>=')) {
2123
return $builder->{$method}($perPage, $columns, $pageName, $page, $total);

0 commit comments

Comments
 (0)