From ee5602a309ab4e4a607d0a6d28a3a728f6ecabe3 Mon Sep 17 00:00:00 2001 From: "Arjay Q. Angeles" Date: Wed, 21 Apr 2021 13:30:39 +0800 Subject: [PATCH] Allow passing of constructor arguments on make method helper. --- src/Html/DataTableHtml.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Html/DataTableHtml.php b/src/Html/DataTableHtml.php index f5b7930..1675b23 100644 --- a/src/Html/DataTableHtml.php +++ b/src/Html/DataTableHtml.php @@ -20,6 +20,10 @@ abstract class DataTableHtml implements DataTableHtmlBuilder */ public static function make() { + if (func_get_args()) { + return (new static(...func_get_args()))->handle(); + } + return app(static::class)->handle(); }