Skip to content
This repository was archived by the owner on Oct 14, 2025. It is now read-only.

Commit 4322f15

Browse files
committed
Replace = with <-
1 parent 8356e36 commit 4322f15

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

R/metadata.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ cache <- rlang::env(
88
metadata_table = rlang::env()
99
)
1010

11-
DATABASE_URL = single_line_str(
11+
DATABASE_URL <- single_line_str(
1212
"https://object-store.rc.nectar.org.au/v1/
1313
AUTH_06d6e008e3e642da99d806ba3ea629c5/metadata/metadata.0.2.3.parquet"
1414
)
@@ -129,7 +129,7 @@ get_metadata <- function(
129129
) {
130130
hash <- c(remote_url, cache_directory) |> paste0(collapse="") |>
131131
hash_sha256()
132-
cached_connection = cache$metadata_table[[hash]]
132+
cached_connection <- cache$metadata_table[[hash]]
133133
if (!is.null(cached_connection) && isTRUE(use_cache)) {
134134
cached_connection
135135
}
@@ -144,7 +144,7 @@ get_metadata <- function(
144144
table <- duckdb() |>
145145
dbConnect(drv = _, read_only = TRUE) |>
146146
tbl(db_path)
147-
cache$metadata_table[[hash]] = table
147+
cache$metadata_table[[hash]] <- table
148148
table
149149
}
150150
}

R/zzz.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#' @importFrom purrr walk
22
#' @importFrom dbplyr remote_con
33
#' @importFrom DBI dbDisconnect
4-
.onUnload = function(libname, pkgname){
4+
.onUnload <- function(libname, pkgname){
55
# Close connections to all cached tables. This should avoid most of the
66
# "Connection is garbage-collected" messages
77
cache$metadata_table |>

0 commit comments

Comments
 (0)