From 1fc0f790d9430428a3178483f3230d230415d600 Mon Sep 17 00:00:00 2001 From: narawat Date: Fri, 28 Aug 2026 19:48:29 +0700 Subject: [PATCH] update --- src/garageS3.jl | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/garageS3.jl b/src/garageS3.jl index 1aecfd0..7086955 100644 --- a/src/garageS3.jl +++ b/src/garageS3.jl @@ -257,8 +257,12 @@ julia> data = String(get_file(storage, "test.json")) "\"{\\\"status\\\": \\\"active\\\"}\"" ``` """ -function get_file(storage::GarageStorage, key::String)::Vector{UInt8} - return AWSS3.s3_get(storage.config, storage.bucket, key) +function get_file(storage::GarageStorage, key::String)::Union{Vector{UInt8}, Nothing} + try + return AWSS3.s3_get(storage.config, storage.bucket, key) + catch + return nothing + end end """ List all object keys in the Garage S3 bucket.