From b10435eeb703a2f44cacffc8bdfbb325578af0fe Mon Sep 17 00:00:00 2001 From: Clint Tseng Date: Tue, 16 May 2017 14:30:51 -0700 Subject: [PATCH] convert/bug: was not converting deviceid metadata types correctly. * resolves opendatakit/build#148. --- lib/convert.js | 2 +- spec/src/convert-question-spec.ls | 2 +- src/convert.ls | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/convert.js b/lib/convert.js index 7facd82..176f999 100644 --- a/lib/convert.js +++ b/lib/convert.js @@ -52,7 +52,7 @@ 'Shape': 'geoshape' }; metadataTypeConversion = { - 'Device Id': 'deviceid', + 'Device ID': 'deviceid', 'Start Time': 'start', 'End Time': 'end', 'Today': 'today', diff --git a/spec/src/convert-question-spec.ls b/spec/src/convert-question-spec.ls index 3414a31..2e65dd1 100644 --- a/spec/src/convert-question-spec.ls +++ b/spec/src/convert-question-spec.ls @@ -84,7 +84,7 @@ describe \type -> expect(result.type).toBe(\barcode) test \metadata -> - deviceid = { type: \metadata, kind: 'Device Id' } |> convert-simple + deviceid = { type: \metadata, kind: 'Device ID' } |> convert-simple expect(deviceid.type).toBe(\deviceid) start = { type: \metadata, kind: 'Start Time' } |> convert-simple diff --git a/src/convert.ls b/src/convert.ls index 7c5b31d..0487336 100644 --- a/src/convert.ls +++ b/src/convert.ls @@ -47,7 +47,7 @@ location-type-conversion = 'Shape': \geoshape metadata-type-conversion = - 'Device Id': \deviceid + 'Device ID': \deviceid 'Start Time': \start 'End Time': \end 'Today': \today