Code Duplication    Length = 9-10 lines in 5 locations

src/ritero/SDK/TwitchTV/TwitchSDK.php 5 locations

@@ 159-167 (lines=9) @@
156
     * @param   integer
157
     * @return  stdClass
158
     */
159
    public function userFollowChannels($user, $limit = null, $offset = null)
160
    {
161
        $query_string = $this->buildQueryString(array(
162
            'limit' => $limit,
163
            'offset' => $offset,
164
        ));
165
166
        return $this->request(sprintf(self::URI_USER_FOLLOWS_CHANNEL, $user) . $query_string);
167
    }
168
169
    /**
170
     * Get the status of a follow relationship
@@ 247-255 (lines=9) @@
244
     * @param   integer
245
     * @return  stdClass
246
     */
247
    public function channelFollows($channel, $limit = null, $offset = null)
248
    {
249
        $query_string = $this->buildQueryString(array(
250
            'limit' => $limit,
251
            'offset' => $offset,
252
        ));
253
254
        return $this->request(sprintf(self::URI_CHANNEL_FOLLOWS, $channel) . $query_string);
255
    }
256
257
    /**
258
     * Get the specified channel's stream
@@ 274-283 (lines=10) @@
271
     * @param   integer
272
     * @return  stdClass
273
     */
274
    public function streamSearch($query, $limit = null, $offset = null)
275
    {
276
        $query_string = $this->buildQueryString(array(
277
            'query' => $query,
278
            'limit' => $limit,
279
            'offset' => $offset,
280
        ));
281
282
        return $this->request(self::URI_STREAMS_SEARCH . $query_string);
283
    }
284
285
    /**
286
     * Summarize streams
@@ 314-323 (lines=10) @@
311
     * @param   boolean
312
     * @return  stdClass
313
     */
314
    public function streamsFeatured($limit = null, $offset = null, $hls = null)
315
    {
316
        $query_string = $this->buildQueryString(array(
317
            'limit' => $limit,
318
            'offset' => $offset,
319
            'hls' => $hls,
320
        ));
321
322
        return $this->request(self::URI_STREAMS_FEATURED . $query_string);
323
    }
324
325
    /**
326
     * Get streams by channel
@@ 407-415 (lines=9) @@
404
     * @param   integer
405
     * @return  stdClass
406
     */
407
    public function gamesTop($limit = null, $offset = null)
408
    {
409
        $query_string = $this->buildQueryString(array(
410
            'limit' => $limit,
411
            'offset' => $offset,
412
        ));
413
414
        return $this->request(self::URI_GAMES_TOP . $query_string);
415
    }
416
417
    /**
418
     * Get HTML code for stream embedding