Added filetype recognition