mirror of
https://github.com/penpot/penpot.git
synced 2025-05-30 05:36:12 +02:00
✨ Avoid reflection on s3 storage backend.
This commit is contained in:
parent
34e5e5c513
commit
ef25f8a721
2 changed files with 15 additions and 9 deletions
|
@ -26,7 +26,10 @@
|
|||
[cuerdas.core :as str]
|
||||
[integrant.core :as ig]
|
||||
[lambdaisland.uri :as u]
|
||||
[promesa.exec :as px]))
|
||||
[promesa.exec :as px])
|
||||
(:import
|
||||
java.io.InputStream))
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Storage Module State
|
||||
|
@ -159,8 +162,9 @@
|
|||
|
||||
;; if the source and destination backends are different, we just
|
||||
;; need to obtain the streams and proceed full copy of the data
|
||||
(with-open [input (-> (resolve-backend storage (:backend object))
|
||||
(impl/get-object-data object))]
|
||||
(with-open [^InputStream input
|
||||
(-> (resolve-backend storage (:backend object))
|
||||
(impl/get-object-data object))]
|
||||
(-> (resolve-backend storage (:backend storage))
|
||||
(impl/put-object object* (impl/content input (:size object))))))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue