|
@@ 91-93 (lines=3) @@
|
| 88 |
|
return $response; |
| 89 |
|
} |
| 90 |
|
|
| 91 |
|
if (false == $this->storage->clientConnect($profileId, $commonName, $ip4, $ip6, $connectedAt)) { |
| 92 |
|
return new ApiResponse('connect', ['ok' => false, 'error' => 'unable to write connect event to log']); |
| 93 |
|
} |
| 94 |
|
|
| 95 |
|
return new ApiResponse('connect', ['ok' => true]); |
| 96 |
|
} |
|
@@ 158-160 (lines=3) @@
|
| 155 |
|
$disconnectedAt = InputValidation::disconnectedAt($request->getPostParameter('disconnected_at')); |
| 156 |
|
$bytesTransferred = InputValidation::bytesTransferred($request->getPostParameter('bytes_transferred')); |
| 157 |
|
|
| 158 |
|
if (false === $this->storage->clientDisconnect($profileId, $commonName, $ip4, $ip6, $connectedAt, $disconnectedAt, $bytesTransferred)) { |
| 159 |
|
return new ApiResponse('disconnect', ['ok' => false, 'error' => 'unable to write disconnect event to log']); |
| 160 |
|
} |
| 161 |
|
|
| 162 |
|
return new ApiResponse('disconnect', ['ok' => true]); |
| 163 |
|
} |