aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLi Xiaoming <lixm.fnst@cn.fujitsu.com>2019-09-27 20:30:15 +0800
committerLi Xiaoming <lixm.fnst@cn.fujitsu.com>2019-09-27 20:30:15 +0800
commitb0aafb16a361b6c3333095c3f300c9efeb980928 (patch)
tree500eda00ae8233ca7b15b577e628f7c84cc2a299
parentef658a08a990e45664aac23ceee20197d807a672 (diff)
Message: == and != may perform type coercion, use === or !== to avoid it. Description: The non-strict equality comparison is allowed to convert its arguments to a common type. That can lead to unexpected results such as ' \t\r\n' == 0 being true. Use the strict equality operators === and !== and be explicit about conversions you require. Bug-AGL: SPEC-2814 Change-Id: I72afe29de46ad93d49537f16a758c33a706246e9 Signed-off-by: Li Xiaoming <lixm.fnst@cn.fujitsu.com>
-rw-r--r--app/main.qml2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/main.qml b/app/main.qml
index 4c4d7a9..2f6bda3 100644
--- a/app/main.qml
+++ b/app/main.qml
@@ -33,7 +33,7 @@ ApplicationWindow {
function findId(tid) {
for(var i = 0; i < libraryModel.count; i++) {
- if(tid == libraryModel.get(i).tid) {
+ if(tid === libraryModel.get(i).tid) {
return i;
}
}