Code Duplication    Length = 10-11 lines in 3 locations

source/API/VKDataStorage.php 1 location

@@ 38-48 (lines=11) @@
35
     * @throws VKException
36
     * @return array
37
     */
38
    protected function get($storageKey, $storageKeys, $userID, $isGlobal) {
39
        parent::isAllowed();
40
        $requestParameters = [
41
            'key'       =>  substr($storageKey, 0, 100),
42
            'keys'      =>  $storageKeys,
43
            'user_id'   =>  $userID,
44
            'global'    =>  ($isGlobal > 1 || $isGlobal < 0) ? 0 : $isGlobal
45
46
        ];
47
        return parent::executeQuery(__FUNCTION__, $requestParameters);
48
    }
49
50
    /**
51
     * Saves a value of variable with the name set by key parameter

source/API/VKUsers.php 2 locations

@@ 112-121 (lines=10) @@
109
     * @return mixed
110
     * @throws VKException
111
     */
112
    public function getSubscriptions($userID, $combineResults = 0, $requestFields = self::standardFields, $resultCount = 20) {
113
        $requestParameters = [
114
            'user_id'   =>  $userID,
115
            'extended'  =>  ($combineResults > 1 || $combineResults < 0) ? 0 : $combineResults,
116
            'count'     =>  $resultCount,
117
            'fields'    =>  $this->returnAllowedFields($requestFields)
118
        ];
119
120
        return parent::executeQuery(__FUNCTION__, $requestParameters);
121
    }
122
123
    /**
124
     * Returns a list of IDs of followers of the user in question, sorted by date added, most recent first
@@ 133-143 (lines=11) @@
130
     * @return mixed
131
     * @throws VKException
132
     */
133
    public function getFollowers($userID, $setOffset = 0, $displayCount = 100, $requestFields = self::standardFields, $nameCase = 'nom') {
134
        $requestParameters = [
135
            'user_id'   =>  $userID,
136
            'offset'    =>  $setOffset,
137
            'count'     =>  $displayCount,
138
            'fields'    =>  $this->returnAllowedFields($requestFields),
139
            'name_case' =>  $this->returnAllowedNC($nameCase)
140
        ];
141
142
        return parent::executeQuery(__FUNCTION__, $requestParameters);
143
    }
144
145
    /**
146
     * Get Nearby Users Based On Current Latitude and Longitude