summaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorLi Xiaoming <lixm.fnst@cn.fujitsu.com>2019-09-27 20:40:58 +0800
committerLi Xiaoming <lixm.fnst@cn.fujitsu.com>2019-09-27 20:40:58 +0800
commit9d56d84d976e6cc88b0ebedbcc3ba55f61cbb1f7 (patch)
tree63e940ea2ef0b4b1e70b5985ed425f7958f646df /app
parentca0a3ba02b714505292021ef6d36b1449e0dc867 (diff)
fix(MediaScanner.qml): Remove qml M126 warningicefish_8.99.1icefish/8.99.18.99.1
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: If0648d063b64ac2b4265006942b9c69991459836 Signed-off-by: Li Xiaoming <lixm.fnst@cn.fujitsu.com>
Diffstat (limited to 'app')
-rw-r--r--app/api/MediaScanner.qml4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/api/MediaScanner.qml b/app/api/MediaScanner.qml
index add261b..8842a18 100644
--- a/app/api/MediaScanner.qml
+++ b/app/api/MediaScanner.qml
@@ -83,10 +83,10 @@ WebSocket {
case msgid.event:
var payload = JSON.parse(JSON.stringify(json[2]))
var event = payload.event
- if (event == "mediascanner/media_added") {
+ if (event === "mediascanner/media_added") {
console.debug("Media playlist is updated")
root.add(json[2].data.Media)
- } else if (event == "mediascanner/media_removed") {
+ } else if (event === "mediascanner/media_removed") {
root.remove(json[2].data.Path)
}
break