From 75627515f473deb670d6084e1b982cd8c35d9c65 Mon Sep 17 00:00:00 2001 From: Artem Bondarenko Date: Mon, 2 Nov 2020 22:14:38 +0200 Subject: [PATCH] added pagination to tags --- src/Model/Tag/IndexResponse.php | 2 +- tests/Api/TagTest.php | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/Model/Tag/IndexResponse.php b/src/Model/Tag/IndexResponse.php index 2bc7cb8..1e8148b 100644 --- a/src/Model/Tag/IndexResponse.php +++ b/src/Model/Tag/IndexResponse.php @@ -42,7 +42,7 @@ final class IndexResponse implements ApiResponse, PagingProvider $model->items = $items; // Fix http urls that is coming from server - $data['paging'] = array_map(function(string $url) { + $data['paging'] = array_map(function (string $url) { return str_replace('http://', 'https://', $url); }, $data['paging']); diff --git a/tests/Api/TagTest.php b/tests/Api/TagTest.php index 9ee43f4..0221997 100644 --- a/tests/Api/TagTest.php +++ b/tests/Api/TagTest.php @@ -14,9 +14,6 @@ namespace Mailgun\Tests\Api; use GuzzleHttp\Psr7\Response; use Mailgun\Api\Tag; use Mailgun\Hydrator\ModelHydrator; -use Mailgun\Model\PaginationResponse; -use Mailgun\Model\Stats\TotalResponse; -use Mailgun\Model\Stats\TotalResponseItem; use Mailgun\Model\Tag\IndexResponse; /**