R/e_message_capture.R
e_message_capture.Rd
Capture a message, warning, or error to take actions
e_message_capture(f)
a function that might return a message, warning, or error
if there was an exception, return its content
e_message_capture(test_message)(1)
#> [[1]]
#> NULL
#>
#> $logs
#> $logs[[1]]
#> $logs[[1]]$timestamp
#> [1] "2023-03-24 00:09:08"
#>
#> $logs[[1]]$type
#> [1] "error"
#>
#> $logs[[1]]$message
#> [1] "object 'test_message' not found"
#>
#>
#>