Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add application/vnd.api+json support so files are saved as .json file #114

Open
ssglopes opened this issue Feb 13, 2024 · 0 comments
Open

Comments

@ssglopes
Copy link

ssglopes commented Feb 13, 2024

Hi, Would it be possible to add contentType: application/vnd.api+json so this package would be compatible with https://laraveljsonapi.io/ as that package expects application/vnd.api+json

    protected function guessFileExtension($response)
    {
        $contentType = $response->headers->get('Content-Type');

        if ($response instanceof JsonResponse ||
            $contentType == 'application/json' ||
            $contentType == 'application/vnd.api+json' // <= would it be possible to add this line 
        ) {
            return 'json';
        }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant