Skip to content

NAs in pluralize vector cause values to not display correctly #717

Open
@rundel

Description

@rundel

See the following reprex:

library(cli)

pluralize('{c(NA_character_)} file{?s}')
#> NA file
pluralize('{c("file1", NA_character_)} file{?s}')
#> NA files
pluralize('{c(NA_character_, "file1")} file{?s}')
#> NA files
pluralize('{c("file1", "file2", NA_character_)} file{?s}')
#> NA files

Created on 2024-08-15 with reprex v2.1.1

I believe the expected behavior should be to have the vector displayed as is with the included NAs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugan unexpected problem or unintended behavior

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions