[Mediacontroller] Remove throwing exception when removing listener
authorTomasz Marciniak <t.marciniak@samsung.com>
Wed, 24 Jun 2015 14:26:26 +0000 (16:26 +0200)
committerTomasz Marciniak <t.marciniak@samsung.com>
Wed, 24 Jun 2015 14:29:58 +0000 (16:29 +0200)
[Verification] Code compiles without errors.

Change-Id: I467ef3098104e3f792a317e1cd0e88779d434089
Signed-off-by: Tomasz Marciniak <t.marciniak@samsung.com>
src/mediacontroller/mediacontroller_api.js

index ac4283acea2b6aadaaf2e0389989f2f8f640f2f1..7af9b643fbea2fa986997c67304907b3994f95ad 100755 (executable)
@@ -64,10 +64,6 @@ ListenerManager.prototype.addListener = function(callback) {
 };
 
 ListenerManager.prototype.removeListener = function(watchId) {
-  if (this.listeners[watchId] === null || this.listeners[watchId] === undefined) {
-    throw new WebAPIException(0, 'Watch id not found.', 'InvalidValuesError');
-  }
-
   if (this.listeners.hasOwnProperty(watchId)) {
     delete this.listeners[watchId];
   }