Skip to content

Commit bb7cd7c

Browse files
authored
Added type to closure. (#7856)
1 parent 91582cd commit bb7cd7c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

http-client.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -382,7 +382,9 @@ If you would like to fake a sequence of responses but do not need to specify a s
382382

383383
If you require more complicated logic to determine what responses to return for certain endpoints, you may pass a closure to the `fake` method. This closure will receive an instance of `Illuminate\Http\Client\Request` and should return a response instance. Within your closure, you may perform whatever logic is necessary to determine what type of response to return:
384384

385-
Http::fake(function ($request) {
385+
use Illuminate\Http\Client\Request;
386+
387+
Http::fake(function (Request $request) {
386388
return Http::response('Hello World', 200);
387389
});
388390

0 commit comments

Comments
 (0)