From 21df3af018f727aa35a8bf3e4f229d7203b8151d Mon Sep 17 00:00:00 2001 From: Kurt Friars Date: Wed, 25 Oct 2023 20:21:11 +0800 Subject: [PATCH] Fix readme method signatures --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 5442e3a..31c34d6 100644 --- a/README.md +++ b/README.md @@ -17,8 +17,8 @@ laravel-hush is a Laravel package that allows you to disable the observers and h - [Usage](#usage) - [withoutObserver(string $observer, Closure $callback)](#withoutobserverstring-observer-closure-callback) - [withoutObservers(array $observers, Closure $callback)](#withoutobserversarray-observers-closure-callback) - - [withoutHandler(string $event, Closure $callback, array $classes)](#withouthandlerstring-event-closure-callback-array-classes) - - [withoutHandlers(array $events, Closure $callback, array $classes)](#withouthandlersarray-events-closure-callback-array-classes) + - [withoutHandler(string $event, Closure $callback, array $classes = [])](#withouthandlerstring-event-closure-callback-array-classes) + - [withoutHandlers(array $events, Closure $callback, array $classes = [])](#withouthandlersarray-events-closure-callback-array-classes) - [Credits](#credits) - [License](#license) - [Security Vulnerabilities](#security-vulnerabilities) @@ -67,7 +67,7 @@ User::withoutObservers([UserObserver::class, ExpirableObserver::class], function }); ``` -### withoutHandler(string $event, Closure $callback, array $classes) +### withoutHandler(string $event, Closure $callback, array $classes = []) This method will disable handlers for the provided event during the execution of the callback. @@ -91,7 +91,7 @@ User::withoutHandler('created', function () { }, [User::class]); ``` -### withoutHandlers(array $events, Closure $callback, array $classes) +### withoutHandlers(array $events, Closure $callback, array $classes = []) This method is the same as `withoutHandler()` but allows you to pass in an array of events to disable handlers for.