If it's missing we get an empty value, but we can't use that with to_string_without_side_effects() so we have to use undefined as the default. Fixes #5142.