@@ -14,12 +14,18 @@ enum ChirpState {
14
14
15
15
class ChirpSDK {
16
16
static const MethodChannel _methods = const MethodChannel ('chirp.io/methods' );
17
- static const EventChannel _stateEvents = const EventChannel ('chirp.io/events/state' );
18
- static const EventChannel _sendingEvents = const EventChannel ('chirp.io/events/sending' );
19
- static const EventChannel _sentEvents = const EventChannel ('chirp.io/events/sent' );
20
- static const EventChannel _receivingEvents = const EventChannel ('chirp.io/events/receiving' );
21
- static const EventChannel _receivedEvents = const EventChannel ('chirp.io/events/received' );
22
- static const EventChannel _errorEvents = const EventChannel ('chirp.io/events/errors' );
17
+ static const EventChannel _stateEvents =
18
+ const EventChannel ('chirp.io/events/state' );
19
+ static const EventChannel _sendingEvents =
20
+ const EventChannel ('chirp.io/events/sending' );
21
+ static const EventChannel _sentEvents =
22
+ const EventChannel ('chirp.io/events/sent' );
23
+ static const EventChannel _receivingEvents =
24
+ const EventChannel ('chirp.io/events/receiving' );
25
+ static const EventChannel _receivedEvents =
26
+ const EventChannel ('chirp.io/events/received' );
27
+ static const EventChannel _errorEvents =
28
+ const EventChannel ('chirp.io/events/errors' );
23
29
24
30
/// Initialise the ChirpSDK
25
31
///
@@ -28,7 +34,7 @@ class ChirpSDK {
28
34
///
29
35
/// [1] : https://developers.chirp.io
30
36
static Future <void > init (String key, String secret) async {
31
- var parameters = { 'key' : key, 'secret' : secret };
37
+ var parameters = {'key' : key, 'secret' : secret};
32
38
await _methods.invokeMethod ('init' , new Map .from (parameters));
33
39
}
34
40
@@ -140,7 +146,7 @@ class ChirpSDK {
140
146
static ChirpStateEvent _stateEvent (dynamic map) {
141
147
if (map is Map ) {
142
148
return new ChirpStateEvent (ChirpState .values[map['previous' ]],
143
- ChirpState .values[map['current' ]]);
149
+ ChirpState .values[map['current' ]]);
144
150
}
145
151
return null ;
146
152
}
0 commit comments