projects
/
platform
/
framework
/
web
/
tizen-extensions-crosswalk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7bc58f8
)
[Download] Add listener type checking
author
Deqing Huang
<deqing.huang@intel.com>
Tue, 3 Dec 2013 10:47:12 +0000
(18:47 +0800)
committer
Deqing Huang
<deqing.huang@intel.com>
Fri, 6 Dec 2013 09:30:11 +0000
(17:30 +0800)
Bug: https://crosswalk-project.org/jira/browse/XWALK-601
download/download_api.js
patch
|
blob
|
history
diff --git
a/download/download_api.js
b/download/download_api.js
index
fb0691e
..
1e7594e
100644
(file)
--- a/
download/download_api.js
+++ b/
download/download_api.js
@@
-242,7
+242,8
@@
exports.start = function(request, listener) {
throw new tizen.WebAPIException(tizen.WebAPIException.TYPE_MISMATCH_ERR);
}
requests[request.uid] = request;
- if (typeof listener != 'undefined') {
+ if (listener !== null) {
+ ensureType(listener, 'object');
exports.setListener(request.uid, listener);
}
postMessage({