@hapiboo/dynamo-flux 1.0.2 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/provider.js +7 -7
  2. package/package.json +1 -1
package/dist/provider.js CHANGED
@@ -113,22 +113,22 @@ var dynamoHelper;
113
113
  attributes.definition = definition;
114
114
  function value(data) {
115
115
  if (typeof data === 'number') {
116
- return { [flux_1.FluxColumn.Number]: data.toString() };
116
+ return { [flux_1.FluxDBColumn.Number]: data.toString() };
117
117
  }
118
118
  else if (typeof data === 'string') {
119
- return { [flux_1.FluxColumn.String]: data };
119
+ return { [flux_1.FluxDBColumn.String]: data };
120
120
  }
121
121
  else if (typeof data === 'boolean') {
122
- return { [flux_1.FluxColumn.Boolean]: data };
122
+ return { [flux_1.FluxDBColumn.Boolean]: data };
123
123
  }
124
124
  else if (Buffer.isBuffer(data)) {
125
- return { [flux_1.FluxColumn.Binary]: data };
125
+ return { [flux_1.FluxDBColumn.Binary]: data };
126
126
  }
127
127
  else if (Array.isArray(data)) {
128
- return { [flux_1.FluxColumn.List]: data.map((item) => { return value(item); }) };
128
+ return { [flux_1.FluxDBColumn.List]: data.map((item) => { return value(item); }) };
129
129
  }
130
130
  else {
131
- return { [flux_1.FluxColumn.Object]: objectValue(data) };
131
+ return { [flux_1.FluxDBColumn.Object]: objectValue(data) };
132
132
  }
133
133
  }
134
134
  attributes.value = value;
@@ -202,7 +202,7 @@ var dynamoHelper;
202
202
  const idx = Array();
203
203
  const attrs = Array();
204
204
  const addedAttributes = Array();
205
- attrs.push({ AttributeName: 'id', AttributeType: flux_1.FluxColumn.String });
205
+ attrs.push({ AttributeName: 'id', AttributeType: flux_1.FluxDBColumn.String });
206
206
  addedAttributes.push('id');
207
207
  if (definition.indexes.length > 0) {
208
208
  definition.indexes.forEach((item) => {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@hapiboo/dynamo-flux",
3
3
  "description": "MK13 Studio Hapiboo - AWS DynamoDB plugin (Flux version)",
4
- "version": "1.0.2",
4
+ "version": "1.1.0",
5
5
  "author": "MK13 Studio",
6
6
  "license": "ISC",
7
7
  "main": "dist/index.js",