daattali / shinyalert

🗯️ Easily create pretty popup messages (modals) in Shiny
https://daattali.com/shiny/shinyalert-demo/
Other
241 stars 26 forks source link

shinyAlert and html with newer R versions #79

Closed RobertOpitz closed 10 months ago

RobertOpitz commented 10 months ago

Dear Dean,

i like this package, it is a great plus and help for my shiny projects.

I have a bug with shinyAlert when using html and newer versions of R (here 4.3.1): On line 304 (shinyAlert v3.0.0 on CRAN), or line 303 of the version here on github, there is a logical expression in which the function nchar() is called without forming a logical expression:

(shinyAlert CRAN version 3.0.0)

if (html && nzchar(params[["text"]])) { ...

This expression was tolerated by previous versions of R (only a warning was thrown). Current versions, however, now make an error out of it and the program stops its execution.

The problem could be solved by converting it to a logical expression. I hope I could improve this nice project.

Sincerely,

Robert

daattali commented 10 months ago

Duplicate of https://github.com/daattali/shinyalert/issues/68 - fixed in dev version

daattali commented 4 months ago

A new version was submitted to CRAN today, it will be on CRAN in a few days