Skip to content
This repository was archived by the owner on Dec 11, 2020. It is now read-only.

Commit 885d5dc

Browse files
authored
fix indentation in readme
1 parent 66fc9f1 commit 885d5dc

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

readme.md

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -266,23 +266,23 @@ it is simply a personal preference for readability and writing less code, when a
266266
it's instantiated.
267267
- The order of parameters that we use when calling a job with its class name is irrelevant to their order in the
268268
Job's constructor signature. i.e.
269-
```php
270-
$this->run(LogUserSearchJob::class, [
271-
'date' => new DateTime(),
272-
'query' => $request->input(),
273-
'resultIds' => $results->lists('id'), // only the ids of the results are required
274-
]);
275-
```
276-
```php
277-
class LogUserSearchJob
269+
```php
270+
$this->run(LogUserSearchJob::class, [
271+
'date' => new DateTime(),
272+
'query' => $request->input(),
273+
'resultIds' => $results->lists('id'), // only the ids of the results are required
274+
]);
275+
```
276+
```php
277+
class LogUserSearchJob
278+
{
279+
public function __construct($query, array $resultIds, DateTime $date)
278280
{
279-
public function __construct($query, array $resultIds, DateTime $date)
280-
{
281-
// ...
282-
}
281+
// ...
283282
}
284-
```
285-
This will work perfectly fine, as long as the key name (`'resultIds' => ...`) is the same as the variable's name in the constructor (`$resultIds`)
283+
}
284+
```
285+
This will work perfectly fine, as long as the key name (`'resultIds' => ...`) is the same as the variable's name in the constructor (`$resultIds`)
286286
- Of course, we need to create and import (`use`) our Job classes with the correct namespaces, but we won't do that here
287287
since this is only to showcase and not intended to be running, for a working example see [Getting Started](#getting-started).
288288

0 commit comments

Comments
 (0)