Skip to content

Commit ec2fb22

Browse files
committed
Working on Encoder
1 parent a35b0c0 commit ec2fb22

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

Sources/Encoder.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -171,14 +171,14 @@ internal extension TLVEncoder.Encoder {
171171
@inline(__always)
172172
func boxNumeric <T: TLVEncodable & FixedWidthInteger> (_ value: T) -> Data {
173173

174-
let endianValue: T
174+
let numericValue: T
175175
switch options.numericFormat {
176176
case .bigEndian:
177-
endianValue = value.bigEndian
177+
numericValue = value.bigEndian
178178
case .littleEndian:
179-
endianValue = value.littleEndian
179+
numericValue = value.littleEndian
180180
}
181-
return endianValue.tlvData
181+
return box(numericValue)
182182
}
183183

184184
func boxEncodable <T: Encodable> (_ value: T) throws -> Data {

0 commit comments

Comments
 (0)