Skip to content

Commit 3cb014a

Browse files
authored
chore: apply standard formatting (#153)
1 parent 9126834 commit 3cb014a

6 files changed

Lines changed: 17 additions & 17 deletions

File tree

src/datatypes/numeric.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,8 @@ function generateFunctions (bufferReader, bufferWriter, size, schema) {
8989
if (offset + size > buffer.length) { throw new PartialReadError() }
9090
const value = buffer[bufferReader](offset)
9191
return {
92-
value: value,
93-
size: size
92+
value,
93+
size
9494
}
9595
}
9696
const writer = (value, buffer, offset) => {

src/datatypes/utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ function readMapper (buffer, offset, { type, mappings }, rootNode) {
2929
}
3030
if (mappedValue == null) throw new Error(value + ' is not in the mappings value')
3131
return {
32-
size: size,
32+
size,
3333
value: mappedValue
3434
}
3535
}

src/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ const ProtoDef = require('./protodef')
22
const proto = new ProtoDef()
33

44
module.exports = {
5-
ProtoDef: ProtoDef,
5+
ProtoDef,
66
Serializer: require('./serializer').Serializer,
77
Parser: require('./serializer').Parser,
88
FullPacketParser: require('./serializer').FullPacketParser,

src/protodef.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ class ProtoDef {
158158
return {
159159
data: value,
160160
metadata: {
161-
size: size
161+
size
162162
},
163163
buffer: buffer.slice(0, size),
164164
fullBuffer: buffer

src/serializer.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ class FullPacketParser extends Transform {
9292
}
9393

9494
module.exports = {
95-
Serializer: Serializer,
96-
Parser: Parser,
97-
FullPacketParser: FullPacketParser
95+
Serializer,
96+
Parser,
97+
FullPacketParser
9898
}

src/utils.js

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -73,13 +73,13 @@ class PartialReadError extends ExtendableError {
7373
}
7474

7575
module.exports = {
76-
getField: getField,
77-
getFieldInfo: getFieldInfo,
78-
addErrorField: addErrorField,
79-
getCount: getCount,
80-
sendCount: sendCount,
81-
calcCount: calcCount,
82-
tryCatch: tryCatch,
83-
tryDoc: tryDoc,
84-
PartialReadError: PartialReadError
76+
getField,
77+
getFieldInfo,
78+
addErrorField,
79+
getCount,
80+
sendCount,
81+
calcCount,
82+
tryCatch,
83+
tryDoc,
84+
PartialReadError
8585
}

0 commit comments

Comments
 (0)