bluejay icon indicating copy to clipboard operation
bluejay copied to clipboard

Make WriteCharacteristic fail if types mismatch

Open DantePuglisi opened this issue 2 years ago • 2 comments

Fixes #263:

Summary of Problem:

There's no way to know if a characteristic has the specified CBCharacteristicWriteType when calling write because if it doesn't, success is returned instead of fail.

Proposed Solution:

In WriteCharacteristic we check that the CBCharacteristic has the passed type as a property, if it doesn't we fail the write.

Testing Completed and Required:

Calling write with a mismatched CBCharacteristicWriteType executes the fail callback.

DantePuglisi avatar May 16 '22 19:05 DantePuglisi

Thank you for submitting this pull request. This looks good to me, but I would like to also get our senior engineer to have a look as well. @nbrooke when you have time can you also review this PR? Thanks.

sakuraehikaru avatar May 16 '22 20:05 sakuraehikaru

Any updates on this? @sakuraehikaru @nbrooke

DantePuglisi avatar Jun 09 '22 09:06 DantePuglisi