Media: don't try to scan non media files with the write hook