Skip to content

Commit c5e2034

Browse files
authored
Apply suggestion from @gadenbuie
1 parent e45fdd3 commit c5e2034

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg-r/R/data_source.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,7 @@ DBISource <- R6::R6Class(
304304

305305
# Default to 'POSIX' if dbms name not found
306306
conn_info <- DBI::dbGetInfo(private$conn)
307-
dbms_name <- if (is.null(conn_info[["dbms.name"]])) "POSIX" else conn_info[["dbms.name"]]
307+
dbms_name <- getElement(conn_info, "dbms.name") %||% "POSIX"
308308

309309
# Remove ' SQL', if exists (SQL is already in the prompt)
310310
gsub(" SQL", "", dbms_name)

0 commit comments

Comments
 (0)