From 4add9a87cc5934958db803983bcb0c564fb91fad Mon Sep 17 00:00:00 2001 From: eai04191 Date: Mon, 9 Sep 2019 10:20:39 +0900 Subject: [PATCH 1/4] Update Fixture --- tests/fixture/DeviantArt/mature.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/fixture/DeviantArt/mature.json b/tests/fixture/DeviantArt/mature.json index 2f60b55..dd7f5d6 100644 --- a/tests/fixture/DeviantArt/mature.json +++ b/tests/fixture/DeviantArt/mature.json @@ -1 +1 @@ -{"version":"1.0","type":"photo","title":"backstage","category":"Anthro > Digital Media > Drawings > Animals","url":"https:\/\/orig00.deviantart.net\/eb50\/f\/2016\/191\/a\/b\/preview_by_rasbii-da9hzby.png","author_name":"Rasbii","author_url":"https:\/\/www.deviantart.com\/rasbii","provider_name":"DeviantArt","provider_url":"https:\/\/www.deviantart.com","safety":"adult","pubdate":"2016-07-09T13:12:42-07:00","community":{"statistics":{"_attributes":{"views":6678,"favorites":127,"comments":39,"downloads":0}}},"rating":"adult","license":{"_attributes":{"type":"text\/html","href":"http:\/\/creativecommons.org\/licenses\/by-nc-nd\/3.0\/"},"0":"Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 License"},"width":"689","height":"619","imagetype":"png","thumbnail_url":"https:\/\/t00.deviantart.net\/eJ1IFDUqQxCrbw2pGNP2ZYtyqk4=\/fit-in\/300x900\/filters:no_upscale():origin()\/pre00\/e504\/th\/pre\/f\/2016\/191\/a\/b\/preview_by_rasbii-da9hzby.png","thumbnail_width":300,"thumbnail_height":270,"thumbnail_url_150":"https:\/\/t00.deviantart.net\/EUshcQ7hG73H6zzfsrnH8xJl5dQ=\/fit-in\/150x150\/filters:no_upscale():origin()\/pre00\/e504\/th\/pre\/f\/2016\/191\/a\/b\/preview_by_rasbii-da9hzby.png","thumbnail_url_200h":"https:\/\/t00.deviantart.net\/ijA0nHI6NA42Ocm0Bfd1rhrDHh0=\/300x200\/filters:fixed_height(100,100):origin()\/pre00\/e504\/th\/pre\/f\/2016\/191\/a\/b\/preview_by_rasbii-da9hzby.png","thumbnail_width_200h":223,"thumbnail_height_200h":200} \ No newline at end of file +{"version":"1.0","type":"photo","title":"backstage","category":"Anthro > Digital Media > Drawings > Animals","url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/bee96c7a-4956-44a4-81aa-7587cf0b85d1\/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7InBhdGgiOiJcL2ZcL2JlZTk2YzdhLTQ5NTYtNDRhNC04MWFhLTc1ODdjZjBiODVkMVwvZGE5aHpieS1iOTY0MGFjMy0xODE1LTRjNzctOTQxMC0wZDQ4ODJhMjBlMjUucG5nIn1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmZpbGUuZG93bmxvYWQiXX0.KUvvn12bGl06p0Nwe7tl7Hxa_JoDRhwh2M3H_1JFJ2Q","author_name":"Rasbii","author_url":"https:\/\/www.deviantart.com\/rasbii","provider_name":"DeviantArt","provider_url":"https:\/\/www.deviantart.com","safety":"adult","pubdate":"2016-07-09T13:12:42-07:00","community":{"statistics":{"_attributes":{"views":6708,"favorites":127,"comments":39,"downloads":0}}},"rating":"adult","license":{"_attributes":{"type":"text\/html","href":"http:\/\/creativecommons.org\/licenses\/by-nc-nd\/3.0\/"},"0":"Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 License"},"width":"689","height":"619","imagetype":"png","thumbnail_url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/bee96c7a-4956-44a4-81aa-7587cf0b85d1\/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png\/v1\/fit\/w_300,h_619,q_70,strp\/backstage_by_rasbii_da9hzby-300w.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9NjE5IiwicGF0aCI6IlwvZlwvYmVlOTZjN2EtNDk1Ni00NGE0LTgxYWEtNzU4N2NmMGI4NWQxXC9kYTloemJ5LWI5NjQwYWMzLTE4MTUtNGM3Ny05NDEwLTBkNDg4MmEyMGUyNS5wbmciLCJ3aWR0aCI6Ijw9Njg5In1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmltYWdlLm9wZXJhdGlvbnMiXX0.XM8Nf4BYEWI5FJEtk9EOYNtQGOlznuuBbs9wFrLOYUw","thumbnail_width":300,"thumbnail_height":270,"thumbnail_url_150":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/bee96c7a-4956-44a4-81aa-7587cf0b85d1\/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png\/v1\/fit\/w_150,h_150,q_70,strp\/backstage_by_rasbii_da9hzby-150.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9NjE5IiwicGF0aCI6IlwvZlwvYmVlOTZjN2EtNDk1Ni00NGE0LTgxYWEtNzU4N2NmMGI4NWQxXC9kYTloemJ5LWI5NjQwYWMzLTE4MTUtNGM3Ny05NDEwLTBkNDg4MmEyMGUyNS5wbmciLCJ3aWR0aCI6Ijw9Njg5In1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmltYWdlLm9wZXJhdGlvbnMiXX0.XM8Nf4BYEWI5FJEtk9EOYNtQGOlznuuBbs9wFrLOYUw","thumbnail_url_200h":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/bee96c7a-4956-44a4-81aa-7587cf0b85d1\/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png\/v1\/fill\/w_223,h_200,q_70,strp\/backstage_by_rasbii_da9hzby-200h.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9NjE5IiwicGF0aCI6IlwvZlwvYmVlOTZjN2EtNDk1Ni00NGE0LTgxYWEtNzU4N2NmMGI4NWQxXC9kYTloemJ5LWI5NjQwYWMzLTE4MTUtNGM3Ny05NDEwLTBkNDg4MmEyMGUyNS5wbmciLCJ3aWR0aCI6Ijw9Njg5In1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmltYWdlLm9wZXJhdGlvbnMiXX0.XM8Nf4BYEWI5FJEtk9EOYNtQGOlznuuBbs9wFrLOYUw","thumbnail_width_200h":223,"thumbnail_height_200h":200} \ No newline at end of file From d049a6f631fd6e60f1b9d69697c51bcf8c22a0f2 Mon Sep 17 00:00:00 2001 From: eai04191 Date: Mon, 9 Sep 2019 10:27:30 +0900 Subject: [PATCH 2/4] =?UTF-8?q?=E3=81=99=E3=81=B9=E3=81=A6wixmp=E3=82=92?= =?UTF-8?q?=E4=BD=BF=E7=94=A8=E3=81=99=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB?= =?UTF-8?q?=E3=81=AA=E3=81=A3=E3=81=9F=E3=81=AE=E3=81=A7=E5=88=86=E3=81=91?= =?UTF-8?q?=E3=82=8B=E5=BF=85=E8=A6=81=E3=81=8C=E3=81=AA=E3=81=8F=E3=81=AA?= =?UTF-8?q?=E3=81=A3=E3=81=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ついでに$data['thumbnail_url']なら常にオプションが付いているのでオプションを含んでいるか判別する必要がなくなった --- app/MetadataResolver/DeviantArtResolver.php | 18 +++-------- .../DeviantArtResolverTest.php | 32 +------------------ tests/fixture/DeviantArt/wixmp.json | 1 - .../DeviantArt/wixmpNoImageOptions.json | 1 - 4 files changed, 5 insertions(+), 47 deletions(-) delete mode 100644 tests/fixture/DeviantArt/wixmp.json delete mode 100644 tests/fixture/DeviantArt/wixmpNoImageOptions.json diff --git a/app/MetadataResolver/DeviantArtResolver.php b/app/MetadataResolver/DeviantArtResolver.php index 1233223..9f17653 100644 --- a/app/MetadataResolver/DeviantArtResolver.php +++ b/app/MetadataResolver/DeviantArtResolver.php @@ -28,20 +28,10 @@ class DeviantArtResolver implements Resolver $data = json_decode($res->getBody()->getContents(), true); $metadata = new Metadata(); - if (preg_match('~\.wixmp\.com$~', parse_url($data['url'])['host'])) { - // アスペクト比を保ったまま、縦か横が最大1024pxになる画像を取得する。 - // Ref: https://support.wixmp.com/en/article/image-service-3835799 - // 作成されていない画像が参照されると403を返すようなので、サイト内で使用されている1024pxにした。 - if (strpos($data['url'], '/v1/fill/')) { - $metadata->image = preg_replace('~/v1/fill/w_\d+,h_\d+(?:,q_\d+),strp/.+\.(jpg|png|webp|gif)~', '/v1/fit/w_1024,h_1024,strp/image.jpg', $data['url']); - } else { - $queryStartPos = strpos($data['url'], '?'); - $metadata->image = substr_replace($data['url'], '/v1/fit/w_1024,h_1024,strp/image.jpg', $queryStartPos, 0); - } - } else { - $metadata->image = $data['url']; - } - + // アスペクト比を保ったまま、縦か横が最大1024pxになる画像を取得する。 + // Ref: https://support.wixmp.com/en/article/image-service-3835799 + // 作成されていない画像が参照されると403を返すようなので、サイト内で使用されている1024pxにした。 + $metadata->image = preg_replace('~/v1/fit/w_\d+,h_\d+(?:,q_\d+),strp/.+\.(jpg|png|webp|gif)~', '/v1/fit/w_1024,h_1024,strp/image.jpg', $data['thumbnail_url']); $metadata->title = $data['title'] ?? ''; $metadata->description = 'By ' . $data['author_name']; diff --git a/tests/Unit/MetadataResolver/DeviantArtResolverTest.php b/tests/Unit/MetadataResolver/DeviantArtResolverTest.php index 88bae98..8247572 100644 --- a/tests/Unit/MetadataResolver/DeviantArtResolverTest.php +++ b/tests/Unit/MetadataResolver/DeviantArtResolverTest.php @@ -18,36 +18,6 @@ class DeviantArtResolverTest extends TestCase } } - public function testWixmp() - { - $responseText = file_get_contents(__DIR__ . '/../../fixture/DeviantArt/wixmp.json'); - - $this->createResolver(DeviantArtResolver::class, $responseText); - - $metadata = $this->resolver->resolve('https://www.deviantart.com/bonchilo/art/Sally-Nox-743562408'); - $this->assertSame('Sally Nox', $metadata->title); - $this->assertSame('By Bonchilo', $metadata->description); - $this->assertStringStartsWith('https://images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com/f/f6b84a8f-053e-4ab6-bd6c-71276a4a9282/dcap4fc-6fd6359c-770b-4515-9e29-e99311d58d57.png/v1/fit/w_1024,h_1024,strp/image.jpg?token=', $metadata->image); - if ($this->shouldUseMock()) { - $this->assertSame('https://backend.deviantart.com/oembed?url=https://www.deviantart.com/bonchilo/art/Sally-Nox-743562408', (string) $this->handler->getLastRequest()->getUri()); - } - } - - public function testWixmpNoImageOptions() - { - $responseText = file_get_contents(__DIR__ . '/../../fixture/DeviantArt/wixmpNoImageOptions.json'); - - $this->createResolver(DeviantArtResolver::class, $responseText); - - $metadata = $this->resolver->resolve('https://www.deviantart.com/messenger-lame/art/rem-639676105'); - $this->assertSame('rem', $metadata->title); - $this->assertSame('By messenger-lame', $metadata->description); - $this->assertStringStartsWith('https://images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com/f/9afa7937-381f-47f0-a8bc-40b9db1faad1/dakuh8p-aea3fc1c-c06e-466b-88ba-d27be8e164e9.png/v1/fit/w_1024,h_1024,strp/image.jpg?token=', $metadata->image); - if ($this->shouldUseMock()) { - $this->assertSame('https://backend.deviantart.com/oembed?url=https://www.deviantart.com/messenger-lame/art/rem-639676105', (string) $this->handler->getLastRequest()->getUri()); - } - } - public function testMature() { $responseText = file_get_contents(__DIR__ . '/../../fixture/DeviantArt/mature.json'); @@ -57,7 +27,7 @@ class DeviantArtResolverTest extends TestCase $metadata = $this->resolver->resolve('https://www.deviantart.com/rasbii/art/backstage-620617246'); $this->assertSame('backstage', $metadata->title); $this->assertSame('By Rasbii', $metadata->description); - $this->assertSame('https://orig00.deviantart.net/eb50/f/2016/191/a/b/preview_by_rasbii-da9hzby.png', $metadata->image); + $this->assertStringStartsWith('https://images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com/f/bee96c7a-4956-44a4-81aa-7587cf0b85d1/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png/v1/fit/w_1024,h_1024,strp/image.jpg?token=', $metadata->image); if ($this->shouldUseMock()) { $this->assertSame('https://backend.deviantart.com/oembed?url=https://www.deviantart.com/rasbii/art/backstage-620617246', (string) $this->handler->getLastRequest()->getUri()); } diff --git a/tests/fixture/DeviantArt/wixmp.json b/tests/fixture/DeviantArt/wixmp.json deleted file mode 100644 index 73fd3c0..0000000 --- a/tests/fixture/DeviantArt/wixmp.json +++ /dev/null @@ -1 +0,0 @@ -{"version":"1.0","type":"photo","title":"Sally Nox","category":"Manga & Anime > Digital Media > Drawings","url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/f6b84a8f-053e-4ab6-bd6c-71276a4a9282\/dcap4fc-6fd6359c-770b-4515-9e29-e99311d58d57.png\/v1\/fill\/w_947,h_844,q_70,strp\/sally__nox_by_bonchilo_dcap4fc-pre.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9MTE0MCIsInBhdGgiOiJcL2ZcL2Y2Yjg0YThmLTA1M2UtNGFiNi1iZDZjLTcxMjc2YTRhOTI4MlwvZGNhcDRmYy02ZmQ2MzU5Yy03NzBiLTQ1MTUtOWUyOS1lOTkzMTFkNThkNTcucG5nIiwid2lkdGgiOiI8PTEyODAifV1dLCJhdWQiOlsidXJuOnNlcnZpY2U6aW1hZ2Uub3BlcmF0aW9ucyJdfQ.zbw4e5eH0NafyMmhM15DKN1NjawSZBUwr2RWQWB7O3o","author_name":"Bonchilo","author_url":"https:\/\/www.deviantart.com\/bonchilo","provider_name":"DeviantArt","provider_url":"https:\/\/www.deviantart.com","safety":"nonadult","pubdate":"2018-05-05T07:18:54-07:00","community":{"statistics":{"_attributes":{"views":243,"favorites":73,"comments":7,"downloads":7}}},"copyright":{"_attributes":{"url":"https:\/\/www.deviantart.com\/bonchilo","year":"2018","entity":"Bonchilo"}},"width":947,"height":844,"imagetype":"","thumbnail_url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/f6b84a8f-053e-4ab6-bd6c-71276a4a9282\/dcap4fc-6fd6359c-770b-4515-9e29-e99311d58d57.png\/v1\/fit\/w_300,h_900,q_70,strp\/sally__nox_by_bonchilo_dcap4fc-300w.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9MTE0MCIsInBhdGgiOiJcL2ZcL2Y2Yjg0YThmLTA1M2UtNGFiNi1iZDZjLTcxMjc2YTRhOTI4MlwvZGNhcDRmYy02ZmQ2MzU5Yy03NzBiLTQ1MTUtOWUyOS1lOTkzMTFkNThkNTcucG5nIiwid2lkdGgiOiI8PTEyODAifV1dLCJhdWQiOlsidXJuOnNlcnZpY2U6aW1hZ2Uub3BlcmF0aW9ucyJdfQ.zbw4e5eH0NafyMmhM15DKN1NjawSZBUwr2RWQWB7O3o","thumbnail_width":300,"thumbnail_height":267,"thumbnail_url_150":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/f6b84a8f-053e-4ab6-bd6c-71276a4a9282\/dcap4fc-6fd6359c-770b-4515-9e29-e99311d58d57.png\/v1\/fit\/w_150,h_150,q_70,strp\/sally__nox_by_bonchilo_dcap4fc-150.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9MTE0MCIsInBhdGgiOiJcL2ZcL2Y2Yjg0YThmLTA1M2UtNGFiNi1iZDZjLTcxMjc2YTRhOTI4MlwvZGNhcDRmYy02ZmQ2MzU5Yy03NzBiLTQ1MTUtOWUyOS1lOTkzMTFkNThkNTcucG5nIiwid2lkdGgiOiI8PTEyODAifV1dLCJhdWQiOlsidXJuOnNlcnZpY2U6aW1hZ2Uub3BlcmF0aW9ucyJdfQ.zbw4e5eH0NafyMmhM15DKN1NjawSZBUwr2RWQWB7O3o","thumbnail_url_200h":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/f6b84a8f-053e-4ab6-bd6c-71276a4a9282\/dcap4fc-6fd6359c-770b-4515-9e29-e99311d58d57.png\/v1\/fill\/w_225,h_200,q_70,strp\/sally__nox_by_bonchilo_dcap4fc-200h.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9MTE0MCIsInBhdGgiOiJcL2ZcL2Y2Yjg0YThmLTA1M2UtNGFiNi1iZDZjLTcxMjc2YTRhOTI4MlwvZGNhcDRmYy02ZmQ2MzU5Yy03NzBiLTQ1MTUtOWUyOS1lOTkzMTFkNThkNTcucG5nIiwid2lkdGgiOiI8PTEyODAifV1dLCJhdWQiOlsidXJuOnNlcnZpY2U6aW1hZ2Uub3BlcmF0aW9ucyJdfQ.zbw4e5eH0NafyMmhM15DKN1NjawSZBUwr2RWQWB7O3o","thumbnail_width_200h":225,"thumbnail_height_200h":200} \ No newline at end of file diff --git a/tests/fixture/DeviantArt/wixmpNoImageOptions.json b/tests/fixture/DeviantArt/wixmpNoImageOptions.json deleted file mode 100644 index 66a07b2..0000000 --- a/tests/fixture/DeviantArt/wixmpNoImageOptions.json +++ /dev/null @@ -1 +0,0 @@ -{"version":"1.0","type":"photo","title":"rem","category":"Manga & Anime > Digital Media > Drawings","url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/9afa7937-381f-47f0-a8bc-40b9db1faad1\/dakuh8p-aea3fc1c-c06e-466b-88ba-d27be8e164e9.png?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7InBhdGgiOiJcL2ZcLzlhZmE3OTM3LTM4MWYtNDdmMC1hOGJjLTQwYjlkYjFmYWFkMVwvZGFrdWg4cC1hZWEzZmMxYy1jMDZlLTQ2NmItODhiYS1kMjdiZThlMTY0ZTkucG5nIn1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmZpbGUuZG93bmxvYWQiXX0.QX4iUJ00rh1B0PXwyBedqQVbEHR6C72Yp0a9DpM5UIg","author_name":"messenger-lame","author_url":"https:\/\/www.deviantart.com\/messenger-lame","provider_name":"DeviantArt","provider_url":"https:\/\/www.deviantart.com","safety":"nonadult","pubdate":"2016-10-12T05:03:58-07:00","community":{"statistics":{"_attributes":{"views":1612,"favorites":313,"comments":9,"downloads":71}}},"tags":"rem, re_zero_kara_hajimeru_isekai_seikatsu","copyright":{"_attributes":{"url":"https:\/\/www.deviantart.com\/messenger-lame","year":"2016","entity":"messenger-lame"}},"width":"750","height":"1000","imagetype":"png","thumbnail_url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/9afa7937-381f-47f0-a8bc-40b9db1faad1\/dakuh8p-aea3fc1c-c06e-466b-88ba-d27be8e164e9.png\/v1\/fit\/w_300,h_900,strp\/rem_by_messenger_lame_dakuh8p-300w.png?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9MTAwMCIsInBhdGgiOiJcL2ZcLzlhZmE3OTM3LTM4MWYtNDdmMC1hOGJjLTQwYjlkYjFmYWFkMVwvZGFrdWg4cC1hZWEzZmMxYy1jMDZlLTQ2NmItODhiYS1kMjdiZThlMTY0ZTkucG5nIiwid2lkdGgiOiI8PTc1MCJ9XV0sImF1ZCI6WyJ1cm46c2VydmljZTppbWFnZS5vcGVyYXRpb25zIl19._gC85PXUst0iqKJCZZSUVonW0YRr5GHj2Qen_Q_95Og","thumbnail_width":300,"thumbnail_height":400,"thumbnail_url_150":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/9afa7937-381f-47f0-a8bc-40b9db1faad1\/dakuh8p-aea3fc1c-c06e-466b-88ba-d27be8e164e9.png\/v1\/fit\/w_150,h_150,strp\/rem_by_messenger_lame_dakuh8p-150.png?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9MTAwMCIsInBhdGgiOiJcL2ZcLzlhZmE3OTM3LTM4MWYtNDdmMC1hOGJjLTQwYjlkYjFmYWFkMVwvZGFrdWg4cC1hZWEzZmMxYy1jMDZlLTQ2NmItODhiYS1kMjdiZThlMTY0ZTkucG5nIiwid2lkdGgiOiI8PTc1MCJ9XV0sImF1ZCI6WyJ1cm46c2VydmljZTppbWFnZS5vcGVyYXRpb25zIl19._gC85PXUst0iqKJCZZSUVonW0YRr5GHj2Qen_Q_95Og","thumbnail_url_200h":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/9afa7937-381f-47f0-a8bc-40b9db1faad1\/dakuh8p-aea3fc1c-c06e-466b-88ba-d27be8e164e9.png\/v1\/fill\/w_150,h_200,strp\/rem_by_messenger_lame_dakuh8p-200h.png?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9MTAwMCIsInBhdGgiOiJcL2ZcLzlhZmE3OTM3LTM4MWYtNDdmMC1hOGJjLTQwYjlkYjFmYWFkMVwvZGFrdWg4cC1hZWEzZmMxYy1jMDZlLTQ2NmItODhiYS1kMjdiZThlMTY0ZTkucG5nIiwid2lkdGgiOiI8PTc1MCJ9XV0sImF1ZCI6WyJ1cm46c2VydmljZTppbWFnZS5vcGVyYXRpb25zIl19._gC85PXUst0iqKJCZZSUVonW0YRr5GHj2Qen_Q_95Og","thumbnail_width_200h":150,"thumbnail_height_200h":200} \ No newline at end of file From db39ee35c29811094b4f27d36c6cdf9fe30d2657 Mon Sep 17 00:00:00 2001 From: eai04191 Date: Tue, 10 Sep 2019 01:27:35 +0900 Subject: [PATCH 3/4] =?UTF-8?q?=E4=B8=8D=E8=A6=81=E3=81=AA=E5=88=A4?= =?UTF-8?q?=E5=AE=9A=E3=81=AE=E5=89=8A=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ref: c0b76e5 --- app/MetadataResolver/DeviantArtResolver.php | 22 +++++++++------------ 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/app/MetadataResolver/DeviantArtResolver.php b/app/MetadataResolver/DeviantArtResolver.php index 9f17653..62bd109 100644 --- a/app/MetadataResolver/DeviantArtResolver.php +++ b/app/MetadataResolver/DeviantArtResolver.php @@ -24,20 +24,16 @@ class DeviantArtResolver implements Resolver public function resolve(string $url): Metadata { $res = $this->client->get('https://backend.deviantart.com/oembed?url=' . $url); - if ($res->getStatusCode() === 200) { - $data = json_decode($res->getBody()->getContents(), true); - $metadata = new Metadata(); + $data = json_decode($res->getBody()->getContents(), true); + $metadata = new Metadata(); - // アスペクト比を保ったまま、縦か横が最大1024pxになる画像を取得する。 - // Ref: https://support.wixmp.com/en/article/image-service-3835799 - // 作成されていない画像が参照されると403を返すようなので、サイト内で使用されている1024pxにした。 - $metadata->image = preg_replace('~/v1/fit/w_\d+,h_\d+(?:,q_\d+),strp/.+\.(jpg|png|webp|gif)~', '/v1/fit/w_1024,h_1024,strp/image.jpg', $data['thumbnail_url']); - $metadata->title = $data['title'] ?? ''; - $metadata->description = 'By ' . $data['author_name']; + // アスペクト比を保ったまま、縦か横が最大1024pxになる画像を取得する。 + // Ref: https://support.wixmp.com/en/article/image-service-3835799 + // 作成されていない画像が参照されると403を返すようなので、サイト内で使用されている1024pxにした。 + $metadata->image = preg_replace('~/v1/fit/w_\d+,h_\d+(?:,q_\d+),strp/.+\.(jpg|png|webp|gif)~', '/v1/fit/w_1024,h_1024,strp/image.jpg', $data['thumbnail_url']); + $metadata->title = $data['title'] ?? ''; + $metadata->description = 'By ' . $data['author_name']; - return $metadata; - } else { - throw new \RuntimeException("{$res->getStatusCode()}: $url"); - } + return $metadata; } } From dc8a70291d028b07b41078f51b7bc765b9f6ac45 Mon Sep 17 00:00:00 2001 From: eai04191 Date: Tue, 10 Sep 2019 22:59:18 +0900 Subject: [PATCH 4/4] =?UTF-8?q?URL=E7=BD=AE=E6=8F=9B=E3=82=92=E5=89=8A?= =?UTF-8?q?=E9=99=A4=20=E3=82=BF=E3=82=B0=E3=82=92=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit なんかもともと入っているurlが十分大きいので置換する必要がないことに気が付きました --- app/MetadataResolver/DeviantArtResolver.php | 8 ++++---- .../Unit/MetadataResolver/DeviantArtResolverTest.php | 11 ++++++----- tests/fixture/DeviantArt/mature.json | 2 +- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/app/MetadataResolver/DeviantArtResolver.php b/app/MetadataResolver/DeviantArtResolver.php index 62bd109..b658436 100644 --- a/app/MetadataResolver/DeviantArtResolver.php +++ b/app/MetadataResolver/DeviantArtResolver.php @@ -27,12 +27,12 @@ class DeviantArtResolver implements Resolver $data = json_decode($res->getBody()->getContents(), true); $metadata = new Metadata(); - // アスペクト比を保ったまま、縦か横が最大1024pxになる画像を取得する。 - // Ref: https://support.wixmp.com/en/article/image-service-3835799 - // 作成されていない画像が参照されると403を返すようなので、サイト内で使用されている1024pxにした。 - $metadata->image = preg_replace('~/v1/fit/w_\d+,h_\d+(?:,q_\d+),strp/.+\.(jpg|png|webp|gif)~', '/v1/fit/w_1024,h_1024,strp/image.jpg', $data['thumbnail_url']); $metadata->title = $data['title'] ?? ''; $metadata->description = 'By ' . $data['author_name']; + $metadata->image = $data['url']; + if (isset($data['tags'])) { + $metadata->tags = explode(', ', $data['tags']); + } return $metadata; } diff --git a/tests/Unit/MetadataResolver/DeviantArtResolverTest.php b/tests/Unit/MetadataResolver/DeviantArtResolverTest.php index 8247572..8e3f500 100644 --- a/tests/Unit/MetadataResolver/DeviantArtResolverTest.php +++ b/tests/Unit/MetadataResolver/DeviantArtResolverTest.php @@ -24,12 +24,13 @@ class DeviantArtResolverTest extends TestCase $this->createResolver(DeviantArtResolver::class, $responseText); - $metadata = $this->resolver->resolve('https://www.deviantart.com/rasbii/art/backstage-620617246'); - $this->assertSame('backstage', $metadata->title); - $this->assertSame('By Rasbii', $metadata->description); - $this->assertStringStartsWith('https://images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com/f/bee96c7a-4956-44a4-81aa-7587cf0b85d1/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png/v1/fit/w_1024,h_1024,strp/image.jpg?token=', $metadata->image); + $metadata = $this->resolver->resolve('https://www.deviantart.com/gatanii69/art/R-15-mabel-and-will-update-686016962'); + $this->assertSame('R-15 mabel and will update', $metadata->title); + $this->assertSame('By gatanii69', $metadata->description); + $this->assertStringStartsWith('https://images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com/f/6854f36d-8010-4cd0-9d62-0cf9b7829764/dbcfq2q-d78c9f6e-dced-4e5c-a345-2a1bfd5d7620.jpg', $metadata->image); + $this->assertSame(['nsfw', 'reversefalls', 'gravityfalls', 'gravityfallsfanart', 'mabelpines', 'billcipher', 'reversemabel', 'willcipher', 'reversebill', 'reversebillcipher', 'mawill'], $metadata->tags); if ($this->shouldUseMock()) { - $this->assertSame('https://backend.deviantart.com/oembed?url=https://www.deviantart.com/rasbii/art/backstage-620617246', (string) $this->handler->getLastRequest()->getUri()); + $this->assertSame('https://backend.deviantart.com/oembed?url=https://www.deviantart.com/gatanii69/art/R-15-mabel-and-will-update-686016962', (string) $this->handler->getLastRequest()->getUri()); } } } diff --git a/tests/fixture/DeviantArt/mature.json b/tests/fixture/DeviantArt/mature.json index dd7f5d6..d583fcb 100644 --- a/tests/fixture/DeviantArt/mature.json +++ b/tests/fixture/DeviantArt/mature.json @@ -1 +1 @@ -{"version":"1.0","type":"photo","title":"backstage","category":"Anthro > Digital Media > Drawings > Animals","url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/bee96c7a-4956-44a4-81aa-7587cf0b85d1\/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7InBhdGgiOiJcL2ZcL2JlZTk2YzdhLTQ5NTYtNDRhNC04MWFhLTc1ODdjZjBiODVkMVwvZGE5aHpieS1iOTY0MGFjMy0xODE1LTRjNzctOTQxMC0wZDQ4ODJhMjBlMjUucG5nIn1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmZpbGUuZG93bmxvYWQiXX0.KUvvn12bGl06p0Nwe7tl7Hxa_JoDRhwh2M3H_1JFJ2Q","author_name":"Rasbii","author_url":"https:\/\/www.deviantart.com\/rasbii","provider_name":"DeviantArt","provider_url":"https:\/\/www.deviantart.com","safety":"adult","pubdate":"2016-07-09T13:12:42-07:00","community":{"statistics":{"_attributes":{"views":6708,"favorites":127,"comments":39,"downloads":0}}},"rating":"adult","license":{"_attributes":{"type":"text\/html","href":"http:\/\/creativecommons.org\/licenses\/by-nc-nd\/3.0\/"},"0":"Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 License"},"width":"689","height":"619","imagetype":"png","thumbnail_url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/bee96c7a-4956-44a4-81aa-7587cf0b85d1\/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png\/v1\/fit\/w_300,h_619,q_70,strp\/backstage_by_rasbii_da9hzby-300w.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9NjE5IiwicGF0aCI6IlwvZlwvYmVlOTZjN2EtNDk1Ni00NGE0LTgxYWEtNzU4N2NmMGI4NWQxXC9kYTloemJ5LWI5NjQwYWMzLTE4MTUtNGM3Ny05NDEwLTBkNDg4MmEyMGUyNS5wbmciLCJ3aWR0aCI6Ijw9Njg5In1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmltYWdlLm9wZXJhdGlvbnMiXX0.XM8Nf4BYEWI5FJEtk9EOYNtQGOlznuuBbs9wFrLOYUw","thumbnail_width":300,"thumbnail_height":270,"thumbnail_url_150":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/bee96c7a-4956-44a4-81aa-7587cf0b85d1\/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png\/v1\/fit\/w_150,h_150,q_70,strp\/backstage_by_rasbii_da9hzby-150.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9NjE5IiwicGF0aCI6IlwvZlwvYmVlOTZjN2EtNDk1Ni00NGE0LTgxYWEtNzU4N2NmMGI4NWQxXC9kYTloemJ5LWI5NjQwYWMzLTE4MTUtNGM3Ny05NDEwLTBkNDg4MmEyMGUyNS5wbmciLCJ3aWR0aCI6Ijw9Njg5In1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmltYWdlLm9wZXJhdGlvbnMiXX0.XM8Nf4BYEWI5FJEtk9EOYNtQGOlznuuBbs9wFrLOYUw","thumbnail_url_200h":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/bee96c7a-4956-44a4-81aa-7587cf0b85d1\/da9hzby-b9640ac3-1815-4c77-9410-0d4882a20e25.png\/v1\/fill\/w_223,h_200,q_70,strp\/backstage_by_rasbii_da9hzby-200h.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9NjE5IiwicGF0aCI6IlwvZlwvYmVlOTZjN2EtNDk1Ni00NGE0LTgxYWEtNzU4N2NmMGI4NWQxXC9kYTloemJ5LWI5NjQwYWMzLTE4MTUtNGM3Ny05NDEwLTBkNDg4MmEyMGUyNS5wbmciLCJ3aWR0aCI6Ijw9Njg5In1dXSwiYXVkIjpbInVybjpzZXJ2aWNlOmltYWdlLm9wZXJhdGlvbnMiXX0.XM8Nf4BYEWI5FJEtk9EOYNtQGOlznuuBbs9wFrLOYUw","thumbnail_width_200h":223,"thumbnail_height_200h":200} \ No newline at end of file +{"version":"1.0","type":"photo","title":"R-15 mabel and will update","category":"Fan Art > Manga & Anime > Digital > Movies & TV","url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/6854f36d-8010-4cd0-9d62-0cf9b7829764\/dbcfq2q-d78c9f6e-dced-4e5c-a345-2a1bfd5d7620.jpg\/v1\/fill\/w_1193,h_670,q_70,strp\/r_15_mabel_and_will_update_by_gatanii69_dbcfq2q-pre.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9ODQyIiwicGF0aCI6IlwvZlwvNjg1NGYzNmQtODAxMC00Y2QwLTlkNjItMGNmOWI3ODI5NzY0XC9kYmNmcTJxLWQ3OGM5ZjZlLWRjZWQtNGU1Yy1hMzQ1LTJhMWJmZDVkNzYyMC5qcGciLCJ3aWR0aCI6Ijw9MTUwMCJ9XV0sImF1ZCI6WyJ1cm46c2VydmljZTppbWFnZS5vcGVyYXRpb25zIl19.6Vj946U_q31oKJDfyUfJGCj-kufd47zV1RjCtN_qtVc","author_name":"gatanii69","author_url":"https:\/\/www.deviantart.com\/gatanii69","provider_name":"DeviantArt","provider_url":"https:\/\/www.deviantart.com","safety":"adult","pubdate":"2017-06-12T06:08:10-07:00","community":{"statistics":{"_attributes":{"views":8322,"favorites":405,"comments":56,"downloads":50}}},"rating":"adult","tags":"nsfw, reversefalls, gravityfalls, gravityfallsfanart, mabelpines, billcipher, reversemabel, willcipher, reversebill, reversebillcipher, mawill","copyright":{"_attributes":{"url":"https:\/\/www.deviantart.com\/gatanii69","year":"2017","entity":"gatanii69"}},"width":1193,"height":670,"imagetype":"","thumbnail_url":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/6854f36d-8010-4cd0-9d62-0cf9b7829764\/dbcfq2q-d78c9f6e-dced-4e5c-a345-2a1bfd5d7620.jpg\/v1\/fit\/w_300,h_842,q_70,strp\/r_15_mabel_and_will_update_by_gatanii69_dbcfq2q-300w.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9ODQyIiwicGF0aCI6IlwvZlwvNjg1NGYzNmQtODAxMC00Y2QwLTlkNjItMGNmOWI3ODI5NzY0XC9kYmNmcTJxLWQ3OGM5ZjZlLWRjZWQtNGU1Yy1hMzQ1LTJhMWJmZDVkNzYyMC5qcGciLCJ3aWR0aCI6Ijw9MTUwMCJ9XV0sImF1ZCI6WyJ1cm46c2VydmljZTppbWFnZS5vcGVyYXRpb25zIl19.6Vj946U_q31oKJDfyUfJGCj-kufd47zV1RjCtN_qtVc","thumbnail_width":300,"thumbnail_height":168,"thumbnail_url_150":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/6854f36d-8010-4cd0-9d62-0cf9b7829764\/dbcfq2q-d78c9f6e-dced-4e5c-a345-2a1bfd5d7620.jpg\/v1\/fit\/w_150,h_150,q_70,strp\/r_15_mabel_and_will_update_by_gatanii69_dbcfq2q-150.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9ODQyIiwicGF0aCI6IlwvZlwvNjg1NGYzNmQtODAxMC00Y2QwLTlkNjItMGNmOWI3ODI5NzY0XC9kYmNmcTJxLWQ3OGM5ZjZlLWRjZWQtNGU1Yy1hMzQ1LTJhMWJmZDVkNzYyMC5qcGciLCJ3aWR0aCI6Ijw9MTUwMCJ9XV0sImF1ZCI6WyJ1cm46c2VydmljZTppbWFnZS5vcGVyYXRpb25zIl19.6Vj946U_q31oKJDfyUfJGCj-kufd47zV1RjCtN_qtVc","thumbnail_url_200h":"https:\/\/images-wixmp-ed30a86b8c4ca887773594c2.wixmp.com\/f\/6854f36d-8010-4cd0-9d62-0cf9b7829764\/dbcfq2q-d78c9f6e-dced-4e5c-a345-2a1bfd5d7620.jpg\/v1\/fill\/w_300,h_168,q_70,strp\/r_15_mabel_and_will_update_by_gatanii69_dbcfq2q-200h.jpg?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1cm46YXBwOjdlMGQxODg5ODIyNjQzNzNhNWYwZDQxNWVhMGQyNmUwIiwiaXNzIjoidXJuOmFwcDo3ZTBkMTg4OTgyMjY0MzczYTVmMGQ0MTVlYTBkMjZlMCIsIm9iaiI6W1t7ImhlaWdodCI6Ijw9ODQyIiwicGF0aCI6IlwvZlwvNjg1NGYzNmQtODAxMC00Y2QwLTlkNjItMGNmOWI3ODI5NzY0XC9kYmNmcTJxLWQ3OGM5ZjZlLWRjZWQtNGU1Yy1hMzQ1LTJhMWJmZDVkNzYyMC5qcGciLCJ3aWR0aCI6Ijw9MTUwMCJ9XV0sImF1ZCI6WyJ1cm46c2VydmljZTppbWFnZS5vcGVyYXRpb25zIl19.6Vj946U_q31oKJDfyUfJGCj-kufd47zV1RjCtN_qtVc","thumbnail_width_200h":300,"thumbnail_height_200h":168} \ No newline at end of file