Code Duplication    Length = 8-8 lines in 2 locations

app/Support/Tencent/XgPusher.php 2 locations

@@ 207-214 (lines=8) @@
204
     * @param  mixed  $user
205
     * @return string[]|null
206
     */
207
    public static function queryDeviceTokensForUser($user)
208
    {
209
        $query = static::createService()->QueryTokensOfAccount(static::accountForUser($user));
210
211
        if (static::parseResult($query, null, null, $result)) {
212
            return is_array($result) ? array_get($result, 'tokens', []) : [];
213
        }
214
    }
215
216
    /**
217
     * Query all tags for the given device token.
@@ 222-229 (lines=8) @@
219
     * @param  string  $deviceToken
220
     * @return string[]|null
221
     */
222
    public static function queryTagsForDeviceToken($deviceToken)
223
    {
224
        $query = static::createService()->QueryTokenTags($deviceToken);
225
226
        if (static::parseResult($query, null, null, $result)) {
227
            return is_array($result) ? array_get($result, 'tags', []) : [];
228
        }
229
    }
230
231
    /**
232
     * Query all tags for the given user.