Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for documents REST API not passing body #18

Closed
wants to merge 22 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@

*.DS_Store
4 changes: 2 additions & 2 deletions sites/bin/compiler/components/video/video.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ Video.prototype.compile = function () {
Video.prototype.canCompileVideo = function () {
// can't compile digital asset videos as they may be advanced videos
// ToDo: Look at making the additional query to determine if advanced video and compile standard video digital assets
var isDigitialAssetVideo = this.contentId;
var isDigitalAssetVideo = this.contentId;

return this.canCompile && !isDigitialAssetVideo;
return this.canCompile && !isDigitalAssetVideo;
};

Video.prototype.hasVisualData = function () {
Expand Down
2 changes: 1 addition & 1 deletion sites/bin/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ gulp.task('install-src', function (done) {
fs.writeFileSync(configPath, configstr);
}

console.log('Project set up, config OEC server in ' + configPath);
console.log('Project set up, config OCM server in ' + configPath);

// install dependencies
console.log('Install dependencies from package.json:');
Expand Down
3 changes: 2 additions & 1 deletion sites/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,8 @@
"develop": "gulp -LL --gulpfile bin/gulpfile.js develop ",
"sync-server": "gulp -LL --gulpfile bin/gulpfile.js sync-server ",
"webhook-server": "gulp -LL --gulpfile bin/gulpfile.js webhook-server ",
"compilation-server": "gulp -LL --gulpfile bin/gulpfile.js compilation-server"
"compilation-server": "gulp -LL --gulpfile bin/gulpfile.js compilation-server",
"update-toolkit": "rm -rf node_modules/ package-lock.json && git pull && npm install"
},
"repository": {
"type": "git",
Expand Down
7 changes: 6 additions & 1 deletion sites/test/server/documentsRouter.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,12 @@ router.post('/*', (req, res) => {
postData.form = body;
}

console.info(' postData=' + JSON.stringify(postData));
if (typeof body == 'string' && typeof JSON.parse(body) == 'object') {
postData.json = true
postData.body = JSON.parse(body)
}

console.log(' postData=' + JSON.stringify(postData));
request(postData).on('response', function (response) {
// fix headers for cross-domain and capitalization issues
serverUtils.fixHeaders(response, res);
Expand Down