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 support for stream resources in FinfoMimeTypeDetector::detectMimeType() #29

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

das-peter
Copy link

As far as I can tell it is valid to call that method with a resource. As such I think it's worth to attempt to detect the mime-type by the stream contents too.
This should be viable via stream_get_contents() while maintaining the stream pointers using ftell() and fseek().

@das-peter
Copy link
Author

@frankdejonge Thank you very much for your prompt response!
I've tried to address your valuable feedback.
The updated version has the stream sample extraction isolated in a dedicated method as it got complex.

@das-peter
Copy link
Author

@frankdejonge Thanks again for your responsiveness. I think I've addressed your points, I'll let you "resolve" the conversations as you'll be the judge if the solutions are satisfactory.

@das-peter
Copy link
Author

Allowed myself to resolve the reviews in the hope to progress this further

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.

2 participants