Improve use of client ID and model number
dblume

dblume commited on 2023-02-22 19:06:38
Showing 4 changed files, with 6 additions and 4 deletions.

... ...
@@ -1,3 +1,4 @@
1 1
 ip_tagger.zip
2 2
 settings.xml
3 3
 .DS_Store
4
+.env
... ...
@@ -1,3 +1,5 @@
1
+-include .env
2
+
1 3
 .PHONY: clean
2 4
 ZIPFILE=ip_tagger.zip
3 5
 
... ...
@@ -32,9 +32,8 @@ function getDeviceId(deviceInfo as object) as String
32 32
         end if
33 33
     end if
34 34
     ' That did not work, so make a custom one.
35
-    clientID = Right(deviceInfo.GetChannelClientId(), 6)
36
-    modelID = deviceInfo.GetModel()
37
-    return clientID + "-" + modelID
35
+    clientID = Right(deviceInfo.GetChannelClientId(), 8)
36
+    return clientID + ":" + deviceInfo.GetModelDetails()["ModelNumber"]
38 37
 end function
39 38
 
40 39
 function executeTask() as void
... ...
@@ -1,7 +1,7 @@
1 1
 title=IP Tagger
2 2
 major_version=2
3 3
 minor_version=2
4
-build_version=0
4
+build_version=1
5 5
 mm_icon_focus_hd=pkg:/images/mm_icon_focus_hd.png
6 6
 mm_icon_focus_sd=pkg:/images/mm_icon_focus_sd.png
7 7
 splash_screen_hd=pkg:/images/splash_screen_hd.png
8 8