Conditions | 3 |
Paths | 2 |
Total Lines | 9 |
Code Lines | 4 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
17 | public function links($controller = null, $parameters = null): LinkResource |
||
18 | { |
||
19 | $resource = LinkResource::create($this->resource, LinkResourceType::ITEM)->link($controller, $parameters); |
||
20 | |||
21 | if (property_exists($this, 'withCollectionLinks') && $this->withCollectionLinks) { |
||
22 | $resource->withCollectionLinks(); |
||
23 | } |
||
24 | |||
25 | return $resource; |
||
26 | } |
||
46 |