Why isn't "has_task_extension" handled by the caller appending it to the filename, rather than here?