Skip to content

Commit 1d16e1f

Browse files
author
Aamod Pisat
committed
Merge branch 'hotfix/3.0.4'
2 parents 81d8431 + c307651 commit 1d16e1f

File tree

6 files changed

+492
-482
lines changed

6 files changed

+492
-482
lines changed

lib/connect.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ var Connect = function (args) {
217217

218218
// initalise the headers
219219
this.headers = {
220-
"User-Agent": 'contentstack-cli/' + pkg.version
220+
"X-User-Agent": 'contentstack-cli/' + pkg.version
221221
};
222222

223223
// merging the args to input

lib/plugin.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ var pluginTemplate = function (_name, pluginName) {
143143
' /*',
144144
' * @beforePublish',
145145
' * @Description: This function is triggered when the publish event occurs.',
146-
' * @Parameters: data - contains un-published entry, it\'s content_type and language.',
146+
' * @Parameters: data - contains published entry, it\'s content_type and language.',
147147
' * @Parameters: next - call this function to pass control to the next subsequent "beforePublish" hook.',
148148
' * It is important to call the next() function, it will affect the publish process,',
149149
' * the entry will get stuck to "in-prgoress" state.',

lib/publish.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ var inputs = {},
2828
api = config.get('contentstack'),
2929
headers = {
3030
api_key: api.api_key,
31-
"User-Agent": 'contentstack-cli/' + pkg.version
31+
"X-User-Agent": 'contentstack-cli/' + pkg.version
3232
},
3333
bound = 100,
3434
backup;
@@ -134,6 +134,7 @@ var publish = function (_event, options) {
134134
delete schema.skip_content_types;
135135
delete options.content_types;
136136
delete options.skip_content_types;
137+
inputs[key] = options[key];
137138
} else if (typeof options[key] === "undefined") {
138139
_params.push(schema[key]);
139140
} else {

0 commit comments

Comments
 (0)