From 7a480062294be7f572d0852d1a0a5e2fe63678eb Mon Sep 17 00:00:00 2001
From: Piotr Kosko
Date: Tue, 14 Jul 2015 14:41:06 +0200
Subject: [PATCH] [BluetoothLE] Fixed validation of callback
[Verification] TCT passrate increases.
Two more tests pass:
BluetoothLEAdapter_startScan_successCallback_invalid_cb
BluetoothLEAdapter_startScan_successCallback_TypeMismatch
Change-Id: Ie11caed21eb18262da2ac28cd92d6a61ccbdd5c5
Signed-off-by: Piotr Kosko
---
src/bluetooth/bluetooth_api.js | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/bluetooth/bluetooth_api.js b/src/bluetooth/bluetooth_api.js
index 75f4981..ee79485 100755
--- a/src/bluetooth/bluetooth_api.js
+++ b/src/bluetooth/bluetooth_api.js
@@ -1371,8 +1371,7 @@ BluetoothLEAdapter.prototype.startScan = function() {
var args = AV.validateMethod(arguments, [{
name: 'successCallback',
- type: AV.Types.LISTENER,
- values: ['onsuccess']
+ type: AV.Types.FUNCTION
}, {
name: 'errorCallback',
type: AV.Types.FUNCTION,
--
2.7.4