I know how that goes, I have done it myself before!

Just to clarify, `is.na` does not fail on `NULL`, it returns a `logical(0)` but gives a warning. So, all I was saying in my note was that if you didn't like how I handled this and wanted to do something elsewhere in say `list_to_dataframe` then I would check for `is.null` first so you avoid warnings.

In terms of the change you suggested, I don't think you want to do that given my other code. I structured things to add the `.id` on if it is `NULL` or `NA`, and then later if it is `NULL`, delete `.id` (need to store flag in a variable because you overwrite `.id`). If you use your suggestion, you would pass `.id = NULL` to `list_to_dataframe` and have `id_as_factor` as `TRUE`, which is not what I think you want, right? There are certainly other ways to write this using the condition you stated, but given my code I don't think you want to do that.