diff options
author | Kevin Decherf <kevin@kdecherf.com> | 2018-10-22 23:08:58 +0200 |
---|---|---|
committer | Kevin Decherf <kevin@kdecherf.com> | 2018-10-22 23:08:58 +0200 |
commit | fc040c749dec0275e562182562c1c1cb89e6cfa1 (patch) | |
tree | 5845f272a8c5f8b1aa7c3e7da0d798b791952cc8 | |
parent | e07fadea76aa7329c4b955a59e74cb867c733706 (diff) | |
download | wallabag-fc040c749dec0275e562182562c1c1cb89e6cfa1.tar.gz wallabag-fc040c749dec0275e562182562c1c1cb89e6cfa1.tar.zst wallabag-fc040c749dec0275e562182562c1c1cb89e6cfa1.zip |
updateOriginUrl: add behavior when diff is fragment and query
Signed-off-by: Kevin Decherf <kevin@kdecherf.com>
-rw-r--r-- | src/Wallabag/CoreBundle/Helper/ContentProxy.php | 1 | ||||
-rw-r--r-- | tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php | 8 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/Wallabag/CoreBundle/Helper/ContentProxy.php b/src/Wallabag/CoreBundle/Helper/ContentProxy.php index 007ee8bb..1a2a330f 100644 --- a/src/Wallabag/CoreBundle/Helper/ContentProxy.php +++ b/src/Wallabag/CoreBundle/Helper/ContentProxy.php | |||
@@ -344,6 +344,7 @@ class ContentProxy | |||
344 | break; | 344 | break; |
345 | case ['fragment']: | 345 | case ['fragment']: |
346 | case ['query']: | 346 | case ['query']: |
347 | case ['fragment', 'query']: | ||
347 | // noop | 348 | // noop |
348 | break; | 349 | break; |
349 | default: | 350 | default: |
diff --git a/tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php b/tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php index c20732cc..3debc457 100644 --- a/tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php +++ b/tests/Wallabag/CoreBundle/Helper/ContentProxyTest.php | |||
@@ -801,6 +801,14 @@ class ContentProxyTest extends TestCase | |||
801 | null, | 801 | null, |
802 | 'example.org', | 802 | 'example.org', |
803 | ], | 803 | ], |
804 | 'fragment and query string in fetched content' => [ | ||
805 | 'https://example.org/hello', | ||
806 | null, | ||
807 | 'https://example.org/hello?foo#world', | ||
808 | 'https://example.org/hello', | ||
809 | null, | ||
810 | 'example.org', | ||
811 | ] | ||
804 | ]; | 812 | ]; |
805 | } | 813 | } |
806 | 814 | ||