File tree Expand file tree Collapse file tree
android/src/main/java/it/iotinga/blelibrary Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -177,15 +177,15 @@ class RNBleManager(
177177
178178 if (options?.contains(" timeout" ) == true ) {
179179 log(Log .DEBUG , " set timeout to ${options[" timeout" ]} " )
180- request.timeout(options[" timeout" ] as Long )
180+ request.timeout(( options[" timeout" ] as Double ).toLong() )
181181 }
182182 if (options?.contains(" preferredPhy" ) == true ) {
183183 log(Log .DEBUG , " set preferredPhy to ${options[" preferredPhy" ]} " )
184- request.usePreferredPhy(options[" preferredPhy" ] as Int )
184+ request.usePreferredPhy(( options[" preferredPhy" ] as Double ).toInt() )
185185 }
186186 if (options?.contains(" logLevel" ) == true ) {
187187 log(Log .DEBUG , " set logLevel to ${options[" logLevel" ]} " )
188- logLevel = options[" logLevel" ] as Int
188+ logLevel = ( options[" logLevel" ] as Double ).toInt()
189189 }
190190
191191 request.enqueue()
You can’t perform that action at this time.
0 commit comments