@@ -4,7 +4,7 @@
44
55import { BRIDGE_ERROR } from '../lib/error'
66
7−function needWeb3(obj) {
7+function web3(obj) {
88 return ('web3' in obj === false)
99 ? (() => { throw BRIDGE_ERROR.MISSING_WEB3 })()
1010 : obj.web3.matchWith({
@@ -13,7 +13,7 @@ function needWeb3(obj) {
1313 });
1414}
1515
16−function needContracts(obj) {
16+function contracts(obj) {
1717 return ('contracts' in obj === false)
1818 ? (() => { throw BRIDGE_ERROR.MISSING_CONTRACTS })()
1919 : obj.contracts.matchWith({
@@ -22,7 +22,7 @@ function needContracts(obj) {
2222 });
2323}
2424
25−function needWallet(obj) {
25+function wallet(obj) {
2626 return ('wallet' in obj === false)
2727 ? (() => { throw BRIDGE_ERROR.MISSING_WALLET })()
2828 : obj.wallet.matchWith({
@@ -31,11 +31,11 @@ function needWallet(obj) {
3131 });
3232}
3333
34−function needAddress(obj) {
35− return needWallet(obj).address;
34+function address(obj) {
35+ return wallet(obj).address;
3636}
3737
38−function needPointCursor(obj) {
38+function pointCursor(obj) {
3939 return ('pointCursor' in obj === false)
4040 ? (() => { throw BRIDGE_ERROR.MISSING_POINT })()
4141 : obj.pointCursor.matchWith({
@@ -44,7 +44,7 @@ function needPointCursor(obj) {
4444 });
4545}
4646
47−function needFromPointCache(obj, point) {
47+function fromPointCache(obj, point) {
4848 return ('pointCache' in obj === false)
4949 ? (() => { throw BRIDGE_ERROR.MISSING_POINT })()
5050 : point in obj.pointCache
@@ -53,10 +53,10 @@ function needFromPointCache(obj, point) {
5353}
5454
5555export {
56− needWeb3,
57− needContracts,
58− needWallet,
59− needAddress,
60− needPointCursor,
61− needFromPointCache
56+ web3,
57+ contracts,
58+ wallet,
59+ address,
60+ pointCursor,
61+ fromPointCache
6262}