Skip to content

Commit df50d88

Browse files
authored
Merge pull request #25 from PaymentRails/PR-3869_update-batch-class-type
Update batch class type
2 parents 66a2db5 + f7c8671 commit df50d88

File tree

3 files changed

+13
-4
lines changed

3 files changed

+13
-4
lines changed

lib/Batch.ts

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,16 @@ export class Batch {
4141
completedAt: string = "";
4242
createdAt: string = "";
4343
updatedAt: string = "";
44-
payments?: Payment[] = [];
44+
payments: {
45+
payments: Payment[];
46+
} & types.Serializer.WithMeta = {
47+
payments: [],
48+
meta: {
49+
records: 0,
50+
page: 0,
51+
pages: 0,
52+
},
53+
};
4554
quoteExpiredAt?: string;
4655

4756
/**
@@ -162,7 +171,7 @@ export class Batch {
162171
}
163172

164173
private _initialize(account: types.Batch.Batch) {
165-
Object.keys(account).forEach(k => {
174+
Object.keys(account).forEach((k) => {
166175
(this as any)[k] = (account as any)[k];
167176
});
168177
}

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "paymentrails",
3-
"version": "0.10.2",
3+
"version": "0.10.3",
44
"description": "",
55
"main": "./dist/index",
66
"types": "./dist/index",

0 commit comments

Comments
 (0)