This line is doing a bit too much. Separate it into three lines: one each setting `is` and `mimeType`, and then the `if`.