Browse files

Capture the remote-file/force-overwrite value at phase call time

In order to allow binding of force-overwrite around a block of crate functions,
propogate it's value into the arguments stored in the action plan invocation
  • Loading branch information...
1 parent 74da9f4 commit 51d7d07af4a8e739d8a8547cbe5650a4aab1d586 @hugoduncan hugoduncan committed Apr 15, 2011
Showing with 5 additions and 1 deletion.
  1. +5 −1 src/pallet/resource/remote_file.clj
@@ -334,4 +334,8 @@ Content can also be copied from a blobstore.
(when-> local-file
;; transfer local file to remote system if required
(transfer-file local-file (str path ".new")))
- (apply-map-> remote-file-resource path options)))
+ (apply-map->
+ remote-file-resource path
+ (merge
+ {:overwrite-changes force-overwrite} ;; capture the value of the flag
+ options))))

0 comments on commit 51d7d07

Please sign in to comment.