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

Check mimetype of the uploaded links to create either a link or a file #30

Conversation

ebrehault
Copy link
Collaborator

No description provided.

Copy link

This pull request has been linked to Shortcut Story #9186: Sitemap: test if url is a web page or a file.

map((response) => (response.headers.get('content-type') || 'text/html').split(';')[0]),
);
} catch (err) {
return of('text/html');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After testing some error cases I couldn't get thiscatch to work. Would a catchError work?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

@ebrehault ebrehault merged commit e6e9da5 into main Mar 18, 2024
2 checks passed
@ebrehault ebrehault deleted the ericbrehault/sc-9186/sitemap-test-if-url-is-a-web-page-or-a-file branch March 18, 2024 08:22
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

Successfully merging this pull request may close these issues.

3 participants