getUser($request), $observedUser)) { throw new AuthorizationFailedException(); } $news = \StudipNews::GetNewsByAuthor($args['id'], true); list($offset, $limit) = $this->getOffsetAndLimit(); return $this->getPaginatedContentResponse( array_slice($news, $offset, $limit), count($news) ); } }