| Total Complexity | 4 |
| Total Lines | 37 |
| Duplicated Lines | 0 % |
| Changes | 7 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 9 | class VisitorLogsService |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * Track a view for a post by ID. |
||
| 13 | * |
||
| 14 | * @param int $postId The post ID |
||
| 15 | * @param null|string $ipAddress The viewer's IP address |
||
| 16 | * @param null|string $userAgent The viewer's user agent |
||
| 17 | * @return Post The updated post |
||
| 18 | */ |
||
| 19 | public function trackPostView(int $postId, ?string $ipAddress, ?string $userAgent = null): Post |
||
| 48 |