Code Duplication    Length = 9-9 lines in 2 locations

src/TwitterAds.php 2 locations

@@ 691-699 (lines=9) @@
688
        $this->accountId = $accountId;
689
    }
690
691
    public function getRequestToken($oauth_callback)
692
    {
693
        $parameters = array();
694
        $parameters['oauth_callback'] = $oauth_callback;
695
        $request = $this->oAuthRequest($this->requestTokenURL(), 'GET', $parameters);
696
        $token = self::parse_parameters($request);
697
698
        return $token;
699
    }
700
701
    /**
702
     * Exchange request token and secret for an access token and
@@ 711-719 (lines=9) @@
708
     * "user_id" => "9436992",
709
     * "screen_name" => "abraham")
710
     */
711
    public function getAccessToken($oauth_verifier)
712
    {
713
        $parameters = array();
714
        $parameters['oauth_verifier'] = $oauth_verifier;
715
        $request = $this->oAuthRequest($this->accessTokenURL(), 'GET', $parameters);
716
        $token = self::parse_parameters($request);
717
718
        return $token;
719
    }
720
721
    // This function takes a input like a=b&a=c&d=e and returns the parsed
722
    // parameters like this