1 | <?php |
||
9 | trait HasFormResponses |
||
10 | { |
||
11 | /** |
||
12 | * Register a deleted model event with the dispatcher. |
||
13 | * |
||
14 | * @param \Closure|string $callback |
||
15 | * |
||
16 | * @return void |
||
17 | */ |
||
18 | abstract public static function deleted($callback); |
||
19 | |||
20 | /** |
||
21 | * Define a polymorphic one-to-many relationship. |
||
22 | * |
||
23 | * @param string $related |
||
24 | * @param string $name |
||
25 | * @param string $type |
||
|
|||
26 | * @param string $id |
||
27 | * @param string $localKey |
||
28 | * |
||
29 | * @return \Illuminate\Database\Eloquent\Relations\MorphMany |
||
30 | */ |
||
31 | abstract public function morphMany($related, $name, $type = null, $id = null, $localKey = null); |
||
32 | |||
33 | /** |
||
34 | * Boot the HasFormResponses trait for the model. |
||
35 | * |
||
36 | * @return void |
||
37 | */ |
||
38 | public static function bootHasFormResponses() |
||
44 | |||
45 | /** |
||
46 | * Get all attached form responses to the model. |
||
47 | * |
||
48 | * @return \Illuminate\Database\Eloquent\Relations\MorphMany |
||
49 | */ |
||
50 | public function formResponses(): MorphMany |
||
54 | } |
||
55 |
This check looks for
@param
annotations where the type inferred by our type inference engine differs from the declared type.It makes a suggestion as to what type it considers more descriptive.
Most often this is a case of a parameter that can be null in addition to its declared types.