Skip to content

Commit 21a4ae3

Browse files
committed
Fix several PHPstan errors
Signed-off-by: Lukas Kämmerling <[email protected]>
1 parent a2097e0 commit 21a4ae3

File tree

4 files changed

+8
-0
lines changed

4 files changed

+8
-0
lines changed

src/Models/Certificates/Certificates.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,7 @@ public function getById(int $id)
147147
if (! HetznerAPIClient::hasError($response)) {
148148
return Certificate::parse(json_decode((string) $response->getBody())->{$this->_getKeys()['one']});
149149
}
150+
return null;
150151
}
151152

152153
/**

src/Models/Model.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ public function __construct(Client $httpClient = null)
2828
*/
2929
public static function parse($input)
3030
{
31+
return null;
3132
}
3233

3334
/**

src/Models/Networks/Network.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,7 @@ public function addSubnet(Subnet $subnet)
9595
'action' => Action::parse(json_decode((string) $response->getBody())->action),
9696
], $response->getHeaders());
9797
}
98+
return null;
9899
}
99100

100101
/**
@@ -113,6 +114,7 @@ public function deleteSubnet(Subnet $subnet)
113114
'action' => Action::parse(json_decode((string) $response->getBody())->action),
114115
], $response->getHeaders());
115116
}
117+
return null;
116118
}
117119

118120
/**
@@ -131,6 +133,7 @@ public function addRoute(Route $route)
131133
'action' => Action::parse(json_decode((string) $response->getBody())->action),
132134
], $response->getHeaders());
133135
}
136+
return null;
134137
}
135138

136139
/**
@@ -149,6 +152,7 @@ public function deleteRoute(Route $route)
149152
'action' => Action::parse(json_decode((string) $response->getBody())->action),
150153
], $response->getHeaders());
151154
}
155+
return null;
152156
}
153157

154158
public function changeIPRange(string $ipRange)
@@ -161,6 +165,7 @@ public function changeIPRange(string $ipRange)
161165
'action' => Action::parse(json_decode((string) $response->getBody())->action),
162166
], $response->getHeaders());
163167
}
168+
return null;
164169
}
165170

166171
/**

src/Models/SSHKeys/SSHKeys.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ public function getById(int $id)
144144
if (! HetznerAPIClient::hasError($response)) {
145145
return SSHKey::parse(json_decode((string) $response->getBody())->ssh_key);
146146
}
147+
return null;
147148
}
148149

149150
/**

0 commit comments

Comments
 (0)