break; case validateRoute('GET', 'users/\\d+/comments'): $comments = new Comments($db, $user); list($result, $totalCount) = $comments->getUserComments((int) $params[1], (int) $_GET["limit"] ?: 10, (int) $_GET["index"] ?: 0); httpResponse($result, $totalCount); break; case validateRoute('GET', 'users/\\d+/peers'): list($seeding, $leeching) = $user->getPeers($params[1] ?: 0); httpResponse(array("seeding" => $seeding, "leeching" => $leeching)); break; case validateRoute('GET', 'users/\\d+/invitees'): $invitees = $user->getInvitees($params[1] ?: 0); httpResponse($invitees); break; case validateRoute('GET', 'users/\\d+/bonuslog'): $bonuslog = $user->getBonusLog($params[1] ?: 0, (int) $_GET["limit"] ?: 10); httpResponse($bonuslog); break; case validateRoute('GET', 'users/\\d+/iplog'): $iplog = $user->getIpLog($params[1] ?: 0, (int) $_GET["limit"] ?: 10); httpResponse($iplog); break; case validateRoute('GET', 'users/\\d+/snatchlog'): httpResponse($user->getSnatchLog((int) $params[1])); break; case validateRoute('GET', 'users/\\d+/watching'): $watching = new Watching($db, $user); httpResponse($watching->query($params[1], (int) $_GET["imdbid"])); break; case validateRoute('POST', 'users/\\d+/watching'): $watching = new Watching($db, $user);