Skip to content

Commit

Permalink
fix: keep old vendor field padding (#2233)
Browse files Browse the repository at this point in the history
  • Loading branch information
spkjp authored and faustbrian committed Mar 13, 2019
1 parent eb6b092 commit 1e42dc1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/crypto/src/transactions/serializers/transaction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { TransactionTypes } from "../../constants";
import { TransactionVersionError } from "../../errors";
import { Address } from "../../identities";
import { configManager } from "../../managers";
import { Bignum, maxVendorFieldLength } from "../../utils";
import { Bignum } from "../../utils";
import { ITransactionData } from "../interfaces";
import { Transaction } from "../types";

Expand Down Expand Up @@ -149,11 +149,11 @@ export class TransactionSerializer {
for (let i = 0; i < fillstart; i++) {
bb.writeByte(vf[i]);
}
for (let i = fillstart; i < maxVendorFieldLength(); i++) {
for (let i = fillstart; i < 64; i++) {
bb.writeByte(0);
}
} else {
for (let i = 0; i < maxVendorFieldLength(); i++) {
for (let i = 0; i < 64; i++) {
bb.writeByte(0);
}
}
Expand Down

0 comments on commit 1e42dc1

Please sign in to comment.