Skip to content

Commit 975aac4

Browse files
nitzanjAmir Tocker
authored andcommitted
Add support for allowMissing parameter in archive creation.
1 parent 90af188 commit 975aac4

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

cloudinary-core/src/main/java/com/cloudinary/ArchiveParams.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ public class ArchiveParams {
2121
private boolean async = false;
2222
private boolean keepDerived = false;
2323
private boolean skipTransformationName = false;
24+
private boolean allowMissing = false;
2425
private String notificationUrl = null;
2526
private String[] targetTags = null;
2627
private String[] tags = null;
@@ -121,6 +122,15 @@ public ArchiveParams skipTransformationName(boolean skipTransformationName) {
121122
return this;
122123
}
123124

125+
public boolean isAllowMissing(){
126+
return allowMissing;
127+
}
128+
129+
public ArchiveParams allowMissing(boolean allowMissing){
130+
this.allowMissing = allowMissing;
131+
return this;
132+
}
133+
124134
public boolean isKeepDerived() {
125135
return keepDerived;
126136
}
@@ -206,6 +216,7 @@ public Map<String, Object> toMap() {
206216
params.put("async", async);
207217
params.put("keep_derived", keepDerived);
208218
params.put("skip_transformation_name", skipTransformationName);
219+
params.put("allow_missing", allowMissing);
209220
if (notificationUrl != null)
210221
params.put("notification_url", notificationUrl);
211222
if (targetTags != null)

cloudinary-core/src/main/java/com/cloudinary/Util.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,7 @@ public static final Map<String, Object> buildArchiveParams(Map options, String t
173173
putEager("transformations", options, params);
174174
putObject("timestamp", options, params, Util.timestamp());
175175
putBoolean("skip_transformation_name", options, params);
176+
putBoolean("allow_missing", options, params);
176177
putObject("expires_at", options, params);
177178
}
178179
return params;

0 commit comments

Comments
 (0)