Remove the nth issue from a IssuesTB object or the nth selector from a
SelectorTB object.
remove_nth(x, ...)
# S3 method for class 'IssuesTB'
remove_nth(x, n, verbose = TRUE, ...)
# S3 method for class 'SelectorTB'
remove_nth(x, n, verbose = TRUE, ...)
# Default S3 method
remove_nth(...)If x is a IssuesTB, it returns the list of issues (a IssuesTB
object) without the nth issue.
If x is a SelectorTB, it returns the list of selector (a SelectorTB
object) without the nth selector
If n exceeds the number of issues or selector, returns the initial
list with a warning.
issues_selector <- init_selector(
source = "Local",
file = file.path(
system.file("data_issues", package = "IssueTrackeR"),
"list_issues.yaml"
)
)
all_issues <- get_issues(selector = issues_selector)
#> The issues will be read from /home/runner/work/_temp/Library/IssueTrackeR/data_issues/list_issues.yaml.
issues_wo_1 <- remove_nth(all_issues, 1)
#> The 1th issue will be removed
issues_wo_3 <- remove_nth(all_issues, 3)
#> The 3th issue will be removed