Skip to content

Commit

Permalink
Removing some print() statements
Browse files Browse the repository at this point in the history
  • Loading branch information
rmbielby committed Feb 12, 2024
1 parent 2050c47 commit 2b7c422
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions R/cookies.R
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,6 @@ cookieBannerUI <- function(id, name = "DfE R-Shiny dashboard template") {
cookieBannerServer <- function(id, input.cookies = NULL, input.remove = NULL) {

Check notice

Code scanning / lintr

Variable and function name style should match snake_case or symbols. Note

Variable and function name style should match snake_case or symbols.

Check notice

Code scanning / lintr

Variable and function name style should match snake_case or symbols. Note

Variable and function name style should match snake_case or symbols.

Check notice

Code scanning / lintr

Variable and function name style should match snake_case or symbols. Note

Variable and function name style should match snake_case or symbols.
moduleServer(id, function(input, output, session) {

Check warning

Code scanning / lintr

no visible global function definition for 'moduleServer' Warning

no visible global function definition for 'moduleServer'
observeEvent(input.cookies(), {

Check warning

Code scanning / lintr

no visible global function definition for 'observeEvent' Warning

no visible global function definition for 'observeEvent'
print(input.cookies()$`_ga_Z967JJVQQX`)
print(input.cookies()$dfe_analytics)
if (!is.null(input.cookies())) {
if (!("dfe_analytics" %in% names(input.cookies()))) {
shinyjs::show(id = "cookieMain")
Expand Down Expand Up @@ -127,7 +125,6 @@ cookieBannerServer <- function(id, input.cookies = NULL, input.remove = NULL) {

# Check for the cookies being authorised
observeEvent(input$cookieAccept, {

Check warning

Code scanning / lintr

no visible global function definition for 'observeEvent' Warning

no visible global function definition for 'observeEvent'
print("cookieAccept pressed")
msg <- list(
name = "dfe_analytics",
value = "granted"
Expand All @@ -140,7 +137,6 @@ cookieBannerServer <- function(id, input.cookies = NULL, input.remove = NULL) {

# Check for the cookies being rejected
observeEvent(input$cookieReject, {

Check warning

Code scanning / lintr

no visible global function definition for 'observeEvent' Warning

no visible global function definition for 'observeEvent'
print("cookieReject pressed")
msg <- list(
name = "dfe_analytics",
value = "denied"
Expand All @@ -154,7 +150,6 @@ cookieBannerServer <- function(id, input.cookies = NULL, input.remove = NULL) {
observeEvent(input$cookieLink, {

Check warning

Code scanning / lintr

no visible global function definition for 'observeEvent' Warning

no visible global function definition for 'observeEvent'
# Need to link here to where further info is located. You can
# updateTabsetPanel to have a cookie page for instance
print("cookieLink pressed")
updateTabsetPanel(session, "navlistPanel", selected = "Support and feedback")

Check warning

Code scanning / lintr

no visible global function definition for 'updateTabsetPanel' Warning

no visible global function definition for 'updateTabsetPanel'

Check notice

Code scanning / lintr

Lines should not be more than 80 characters. This line is 83 characters. Note

Lines should not be more than 80 characters. This line is 83 characters.
})

Expand All @@ -163,7 +158,6 @@ cookieBannerServer <- function(id, input.cookies = NULL, input.remove = NULL) {
msg <- list(name = "dfe_analytics", value = "denied")
session$sendCustomMessage("cookie-remove", msg)
session$sendCustomMessage("analytics-consent", msg)
print(input$cookies)
})
})
}

0 comments on commit 2b7c422

Please sign in to comment.