From: Pawel Andruszkiewicz
Date: Tue, 21 Apr 2015 08:00:36 +0000 (+0200)
Subject: Fixed validation of method calls, appropriate parameter type should be FUNCTION.
X-Git-Tag: submit/tizen_tv/20150603.064601~1^2~150
X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3535646260c434d0ed48e3735404e51064868c8d;p=platform%2Fcore%2Fapi%2Fwebapi-plugins.git
Fixed validation of method calls, appropriate parameter type should be FUNCTION.
Change-Id: Ia09c1d93bb2f161e21544811b001536f0d4d222f
---
diff --git a/src/nfc/nfc_api.js b/src/nfc/nfc_api.js
index 6f63f301..cb8ae021 100644
--- a/src/nfc/nfc_api.js
+++ b/src/nfc/nfc_api.js
@@ -407,8 +407,7 @@ NFCAdapter.prototype.addCardEmulationModeChangeListener = function() {
var args = validator_.validateArgs(arguments, [
{
name: 'callback',
- type: types_.LISTENER,
- values: ['onchanged']
+ type: types_.FUNCTION
}
]);
@@ -449,8 +448,7 @@ NFCAdapter.prototype.addTransactionEventListener = function() {
},
{
name: 'callback',
- type: types_.LISTENER,
- values: ['ondetected']
+ type: types_.FUNCTION
}
]);
@@ -510,8 +508,7 @@ NFCAdapter.prototype.addActiveSecureElementChangeListener = function() {
var args = validator_.validateArgs(arguments, [
{
name: 'callback',
- type: types_.LISTENER,
- values: ['onchanged']
+ type: types_.FUNCTION
}
]);
@@ -1046,8 +1043,7 @@ NFCPeer.prototype.setReceiveNDEFListener = function() {
var args = validator_.validateArgs(arguments, [
{
name: 'listener',
- type: types_.LISTENER,
- values: ['onsuccess']
+ type: types_.FUNCTION
}
]);
diff --git a/src/radio/radio_api.js b/src/radio/radio_api.js
index 672f4ca1..eacc8078 100644
--- a/src/radio/radio_api.js
+++ b/src/radio/radio_api.js
@@ -328,8 +328,7 @@ FMRadioManager.prototype.unsetFMRadioInterruptedListener = function() {
FMRadioManager.prototype.setAntennaChangeListener = function() {
var args = validator_.validateArgs(arguments, [ {
name : 'changeCallback',
- type : types_.LISTENER,
- values : [ 'onchange' ]
+ type : types_.FUNCTION
} ]);
antennaCBmanager.FMRadioAntennaChangeSet(args.changeCallback);