Skip to content

Commit 79c2a26

Browse files
committed
Remove CoreController and fix tests
1 parent 8570893 commit 79c2a26

File tree

9 files changed

+84
-337
lines changed

9 files changed

+84
-337
lines changed

README.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,14 @@ import CurrencyRateController from 'gaba';
7979

8080
The CurrencyRateController passively polls for an ETH-to-fiat exchange rate based on a chosen currency.
8181

82+
### KeyringController
83+
84+
```ts
85+
import KeyringController from 'gaba';
86+
```
87+
88+
The KeyringController is responsible for establishing and managing Ethereum address-based identities.
89+
8290
### NetworkController
8391

8492
```ts
@@ -125,7 +133,13 @@ The ShapeShiftController exposes functions for creating ShapeShift purchases and
125133
import TokenRatesController from 'gaba';
126134
```
127135

128-
The TokenRatesController passively polls for token-to-ETH exchange rates based on a list of available tokens.
136+
### util
137+
138+
```ts
139+
import util from 'gaba';
140+
```
141+
142+
The util module exposes a set of utility functions for common operations like gas estimation and generating crypto-buying URLs.
129143

130144
## Concepts
131145

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@
2424
],
2525
"coverageThreshold": {
2626
"global": {
27-
"branches": 80,
28-
"functions": 80,
29-
"lines": 80,
30-
"statements": 80
27+
"branches": 100,
28+
"functions": 100,
29+
"lines": 100,
30+
"statements": 100
3131
}
3232
}
3333
},

src/AddressBookController.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,10 @@ export class AddressBookController extends BaseController<AddressBookState, Base
4343
}
4444

4545
/**
46-
* Add or update a contact entry by address
47-
*
48-
* @param address - Recipient address to add or update
49-
* @param name - Nickname to associate with this address
46+
* Remove all contract entries
5047
*/
51-
set(address: string, name: string) {
52-
this.addressBook.set(address, { address, name });
48+
clear() {
49+
this.addressBook.clear();
5350
this.update({ addressBook: Array.from(this.addressBook.values()) });
5451
}
5552

@@ -64,10 +61,13 @@ export class AddressBookController extends BaseController<AddressBookState, Base
6461
}
6562

6663
/**
67-
* Remove all contract entries
64+
* Add or update a contact entry by address
65+
*
66+
* @param address - Recipient address to add or update
67+
* @param name - Nickname to associate with this address
6868
*/
69-
clear() {
70-
this.addressBook.clear();
69+
set(address: string, name: string) {
70+
this.addressBook.set(address, { address, name });
7171
this.update({ addressBook: Array.from(this.addressBook.values()) });
7272
}
7373
}

src/CoreController.ts

Lines changed: 0 additions & 297 deletions
This file was deleted.

0 commit comments

Comments
 (0)