|
@@ 182-184 (lines=3) @@
|
| 179 |
|
throw new Error('ClientData type is invalid', ERR_BAD_TYPE); |
| 180 |
|
} |
| 181 |
|
|
| 182 |
|
if(isset($cli->origin) && $cli->origin !== $request->appId) { |
| 183 |
|
throw new Error('App ID does not match the origin', ERR_NO_MATCHING_ORIGIN); |
| 184 |
|
} |
| 185 |
|
|
| 186 |
|
$registration = new Registration(); |
| 187 |
|
$offs = 1; |
|
@@ 314-316 (lines=3) @@
|
| 311 |
|
if($req === null) { |
| 312 |
|
throw new Error('No matching request found', ERR_NO_MATCHING_REQUEST ); |
| 313 |
|
} |
| 314 |
|
if(isset($decodedClient->origin) && $decodedClient->origin !== $req->appId) { |
| 315 |
|
throw new Error('App ID does not match the origin', ERR_NO_MATCHING_ORIGIN); |
| 316 |
|
} |
| 317 |
|
foreach ($registrations as $reg) { |
| 318 |
|
if( !is_object( $reg ) ) { |
| 319 |
|
throw new \InvalidArgumentException('$registrations of doAuthenticate() method only accepts array of object.'); |