Skip to content

Commit

Permalink
BXC-4771 DRY up code and update limit
Browse files Browse the repository at this point in the history
  • Loading branch information
sharonluong committed Nov 18, 2024
1 parent 8fa0303 commit e08ebc5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,9 @@ private void zipFiles(WorkObject workObject, AccessGroupSet agentPrincipals, Pat

Map<String, Integer> duplicates = new HashMap<>();
int count = 0;
var loopLimit = getLoopLimit(memberObjects.size());
for (ContentObject memberObject : memberObjects ) {
if (count == getLoopLimit(memberObjects.size())) {
if (count == loopLimit) {
break;
}
if (!(memberObject instanceof FileObject)) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@
<property name="aclService" ref="aclService"/>
<property name="repoObjLoader" ref="repositoryObjectLoader"/>
<property name="basePath" value="${data.dir}/zip/"/>
<property name="fileLimit" value="500" />
<property name="fileLimit" value="100" />
</bean>

<bean class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
Expand Down

0 comments on commit e08ebc5

Please sign in to comment.