Skip to content

Commit

Permalink
Merge pull request #1424 from contentstack/fix/dev
Browse files Browse the repository at this point in the history
fixed the entry migration script for contentTypes
  • Loading branch information
cs-raj authored Jun 4, 2024
2 parents e3d4694 + 811cf3a commit 301d39f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ export function entryCreateScript(contentType) {
const entriesSearchResponse = await managementAPIClient
.stack({ api_key: stackSDKInstance.api_key, branch_uid: branchName })
.contentType('${contentType}')
.contentType(contentType)
.entry()
.query(requestObject)
.find();
Expand All @@ -482,7 +482,7 @@ export function entryCreateScript(contentType) {
if (skip >= entriesSearchResponse.count) {
return entries;
}
return await getEntries(branchName, skip, limit, entries);
return await getEntries(branchName, contentType, skip, limit, entries);
}
return entries;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ export function entryCreateUpdateScript(contentType) {
const entriesSearchResponse = await managementAPIClient
.stack({ api_key: stackSDKInstance.api_key, branch_uid: branchName })
.contentType('${contentType}')
.contentType(contentType)
.entry()
.query(requestObject)
.find();
Expand All @@ -496,7 +496,7 @@ export function entryCreateUpdateScript(contentType) {
if (skip >= entriesSearchResponse.count) {
return entries;
}
return await getEntries(branchName, skip, limit, entries);
return await getEntries(branchName, contentType, skip, limit, entries);
}
return entries;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ export function entryUpdateScript(contentType) {
const entriesSearchResponse = await managementAPIClient
.stack({ api_key: stackSDKInstance.api_key, branch_uid: branchName })
.contentType('${contentType}')
.contentType(contentType)
.entry()
.query(requestObject)
.find();
Expand Down

0 comments on commit 301d39f

Please sign in to comment.