detect file infomation more accurately

There are several reasons for this tuning:

* there is only one "pdf" item in current mine map, no need to find which is "pdf"
* find "image" in the mine string is confusing and regard ".dmg" and ".iso"  as "image"s as well.
* ``image/*``, ``text/*``, ``audio/*`` and ``video/*`` should be safe to match the mine infomation (with its prefix) while the others are not (such as ``application/*``)
* remove the duplicate line searching for "pdf"