Check mime type with substrings and add some debug messages

Conflicts:
	application/eyepiece.cpp