@@ -13,21 +13,30 @@ export default class Client {
1313 this . config = config ;
1414 }
1515
16- public pushMessage ( to : string , messages : Line . Message | Line . Message [ ] ) : Promise < any > {
16+ public pushMessage (
17+ to : string ,
18+ messages : Line . Message | Line . Message [ ] ,
19+ ) : Promise < any > {
1720 return this . post ( URL . push , {
1821 messages : toArray ( messages ) ,
1922 to,
2023 } ) ;
2124 }
2225
23- public replyMessage ( replyToken : string , messages : Line . Message | Line . Message [ ] ) : Promise < any > {
26+ public replyMessage (
27+ replyToken : string ,
28+ messages : Line . Message | Line . Message [ ] ,
29+ ) : Promise < any > {
2430 return this . post ( URL . reply , {
2531 messages : toArray ( messages ) ,
2632 replyToken,
2733 } ) ;
2834 }
2935
30- public multicast ( to : string [ ] , messages : Line . Message | Line . Message [ ] ) : Promise < any > {
36+ public multicast (
37+ to : string [ ] ,
38+ messages : Line . Message | Line . Message [ ] ,
39+ ) : Promise < any > {
3140 return this . post ( URL . multicast , {
3241 messages : toArray ( messages ) ,
3342 to,
@@ -38,36 +47,44 @@ export default class Client {
3847 return this . get ( URL . profile ( userId ) ) ;
3948 }
4049
41- public getGroupMemberProfile ( groupId : string , userId : string ) : Promise < Line . Profile > {
50+ public getGroupMemberProfile (
51+ groupId : string ,
52+ userId : string ,
53+ ) : Promise < Line . Profile > {
4254 return this . get ( URL . groupMemberProfile ( groupId , userId ) ) ;
4355 }
4456
45- public getRoomMemberProfile ( roomId : string , userId : string ) : Promise < Line . Profile > {
57+ public getRoomMemberProfile (
58+ roomId : string ,
59+ userId : string ,
60+ ) : Promise < Line . Profile > {
4661 return this . get ( URL . roomMemberProfile ( roomId , userId ) ) ;
4762 }
4863
4964 public getGroupMemberIds ( groupId : string ) : Promise < string [ ] > {
5065 const load = ( start ?: string ) : Promise < string [ ] > =>
51- this . get ( URL . groupMemberIds ( groupId , start ) )
52- . then ( ( res : { memberIds : string [ ] , next ?: string } ) => {
66+ this . get (
67+ URL . groupMemberIds ( groupId , start ) ,
68+ ) . then ( ( res : { memberIds : string [ ] ; next ?: string } ) => {
5369 if ( ! res . next ) {
5470 return res . memberIds ;
5571 }
5672
57- return load ( res . next ) . then ( ( extraIds ) => res . memberIds . concat ( extraIds ) ) ;
73+ return load ( res . next ) . then ( extraIds => res . memberIds . concat ( extraIds ) ) ;
5874 } ) ;
5975 return load ( ) ;
6076 }
6177
6278 public getRoomMemberIds ( roomId : string ) : Promise < string [ ] > {
6379 const load = ( start ?: string ) : Promise < string [ ] > =>
64- this . get ( URL . roomMemberIds ( roomId , start ) )
65- . then ( ( res : { memberIds : string [ ] , next ?: string } ) => {
80+ this . get (
81+ URL . roomMemberIds ( roomId , start ) ,
82+ ) . then ( ( res : { memberIds : string [ ] ; next ?: string } ) => {
6683 if ( ! res . next ) {
6784 return res . memberIds ;
6885 }
6986
70- return load ( res . next ) . then ( ( extraIds ) => res . memberIds . concat ( extraIds ) ) ;
87+ return load ( res . next ) . then ( extraIds => res . memberIds . concat ( extraIds ) ) ;
7188 } ) ;
7289 return load ( ) ;
7390 }
0 commit comments