]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
Merge pull request #2733 from wallabag/fix-no-matching-response
authorJeremy Benoist <j0k3r@users.noreply.github.com>
Sun, 8 Jan 2017 09:22:31 +0000 (10:22 +0100)
committerGitHub <noreply@github.com>
Sun, 8 Jan 2017 09:22:31 +0000 (10:22 +0100)
Fixed API error No matching accepted Response format could be determined

app/config/config.yml

index 591b5294aa08536e2cb6834a836bf6808703c81e..05c82e4347b43f3d9a2127378dda640ff8463246 100644 (file)
@@ -148,9 +148,9 @@ fos_rest:
     format_listener:
         enabled: true
         rules:
-            - { path: "^/api/entries/([0-9]+)/export.(.*)", priorities: ['epub', 'mobi', 'pdf', 'txt', 'csv'], fallback_format: false, prefer_extension: false }
-            - { path: "^/api", priorities: ['json', 'xml'], fallback_format: false, prefer_extension: false }
-            - { path: "^/annotations", priorities: ['json', 'xml'], fallback_format: false, prefer_extension: false }
+            - { path: "^/api/entries/([0-9]+)/export.(.*)", priorities: ['epub', 'mobi', 'pdf', 'txt', 'csv'], fallback_format: json, prefer_extension: false }
+            - { path: "^/api", priorities: ['json', 'xml'], fallback_format: json, prefer_extension: false }
+            - { path: "^/annotations", priorities: ['json', 'xml'], fallback_format: json, prefer_extension: false }
             # for an unknown reason, EACH REQUEST goes to FOS\RestBundle\EventListener\FormatListener
             # so we need to add custom rule for custom api export but also for all other routes of the application...
             - { path: '^/', priorities: ['text/html', '*/*'], fallback_format: html, prefer_extension: false }