Last active
June 23, 2020 13:48
-
-
Save hadley/5a56f0519ad57e13214ab2a72197ee87 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# need + validate ----------------------------------------------------------- | |
validate( | |
need( | |
mzfinder::check_mzr_object(ms_object$mzr_connection), | |
"Wasn't able to connect to MS file" | |
) | |
) | |
validate( | |
need(!is.null(input$ppm_input), "ppm_input must not be null"), | |
need(input$ppm_input > 0L, "ppm_input must be > 0") | |
) | |
# if + validate ----------------------------------------------------------- | |
if (!mzfinder::check_mzr_object(ms_object$mzr_connection)) { | |
validate("Wasn't able to connect to MS file") | |
} | |
if (is.null(input$ppm_input)) { | |
validate("ppm_input must not be null") | |
} else if (input$ppm_input <= 0L) { | |
validate("ppm_input must be > 0") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment