Skip to content

Commit f2aac7f

Browse files
committed
Clean up
1 parent dc8ec9e commit f2aac7f

File tree

3 files changed

+4
-5
lines changed

3 files changed

+4
-5
lines changed

src/Endpoint/Concerns/SavesData.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,6 @@ private function assertFieldsExist(array $data)
131131
*/
132132
private function assertFieldsWritable(array $data, $model, Context $context)
133133
{
134-
135134
foreach ($this->resource->getSchema()->getFields() as $field) {
136135
if (! has_value($data, $field)) {
137136
continue;

src/Endpoint/Index.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ private function buildUrl(Request $request, array $overrideParams = []): string
123123
return $selfUrl.($queryString ? '?'.$queryString : '');
124124
}
125125

126-
private function buildPaginationLinks(Request $request, int $offset, ?int $limit, int $count, ?int $total)
126+
private function buildPaginationLinks(Request $request, int $offset, ?int $limit, int $count, ?int $total): array
127127
{
128128
$paginationLinks = [];
129129
$schema = $this->resource->getSchema();
@@ -153,7 +153,7 @@ private function buildPaginationLinks(Request $request, int $offset, ?int $limit
153153
return $paginationLinks;
154154
}
155155

156-
private function sort($query, Context $context)
156+
private function sort($query, Context $context): void
157157
{
158158
$schema = $this->resource->getSchema();
159159

@@ -202,7 +202,7 @@ private function parseSort(string $string): array
202202
return $sort;
203203
}
204204

205-
private function paginate($query, Context $context)
205+
private function paginate($query, Context $context): array
206206
{
207207
$schema = $this->resource->getSchema();
208208
$queryParams = $context->getRequest()->getQueryParams();

src/Schema/Concerns/HasMeta.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/*
4-
* This file is part of Forust.
4+
* This file is part of tobyz/json-api-server.
55
*
66
* (c) Toby Zerner <[email protected]>
77
*

0 commit comments

Comments
 (0)