Added MIME detection to File class