File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -115,7 +115,7 @@ class Serial extends EventTarget {
115115 async disconnect ( callback ) {
116116 let result = false ;
117117 try {
118- result = await this . _protocol ? .disconnect ( ) ;
118+ result = await this . _protocol . disconnect ( ) ;
119119 } catch ( error ) {
120120 console . error ( `${ this . logHead } Error during disconnect:` , error ) ;
121121 }
@@ -129,7 +129,7 @@ class Serial extends EventTarget {
129129 async send ( data , callback ) {
130130 let result ;
131131 try {
132- result = ( await this . _protocol ? .send ( data , callback ) ) ?? { bytesSent : 0 } ;
132+ result = ( await this . _protocol . send ( data , callback ) ) ?? { bytesSent : 0 } ;
133133 } catch ( error ) {
134134 result = { bytesSent : 0 } ;
135135 console . error ( `${ this . logHead } Error sending data:` , error ) ;
You can’t perform that action at this time.
0 commit comments