Fixed JsonRpcSigner for promises and made address optional again.

This commit is contained in:
Richard Moore 2018-06-26 17:49:54 -04:00
parent 98ea4b59a0
commit 0b35f1959a
No known key found for this signature in database
GPG Key ID: 525F70A6FCABC295
5 changed files with 6 additions and 6 deletions

2
dist/ethers.d.ts vendored
View File

@ -501,7 +501,7 @@ declare module 'ethers/providers/json-rpc-provider' {
export class JsonRpcProvider extends Provider {
readonly connection: ConnectionInfo;
constructor(url?: ConnectionInfo | string, network?: Networkish);
getSigner(address: string): JsonRpcSigner;
getSigner(address?: string): JsonRpcSigner;
listAccounts(): Promise<Array<string>>;
send(method: string, params: any): Promise<any>;
perform(method: string, params: any): Promise<any>;

2
dist/ethers.js vendored
View File

@ -10187,7 +10187,7 @@ var JsonRpcSigner = /** @class */ (function (_super) {
});
}
return properties_1.resolveProperties(tx).then(function (tx) {
return _this.provider.send('eth_sendTransaction', [transaction]);
return _this.provider.send('eth_sendTransaction', [tx]);
});
};
JsonRpcSigner.prototype.signMessage = function (message) {

2
dist/ethers.min.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -119,7 +119,7 @@ export class JsonRpcSigner extends Signer {
}
return resolveProperties(tx).then((tx) => {
return this.provider.send('eth_sendTransaction', [ transaction ]);
return this.provider.send('eth_sendTransaction', [ tx ]);
});
}
@ -190,7 +190,7 @@ export class JsonRpcProvider extends Provider {
}
getSigner(address: string): JsonRpcSigner {
getSigner(address?: string): JsonRpcSigner {
return new JsonRpcSigner(this, address);
}