Fix for svg fonts. Fixes #60

This should fix issue #60. Now the file content is also used to determine the file type images and fonts.
Why do we need to be threaded?