Commit 70a6e17
authored
Fix LiveSync calls cosecutive times (#2973)
When CLI is used as a library, the LiveSync method can be called consecutive times for the same projects, but with different device identifiers. For example we may want to start LiveSync on devices with identifiers [ A, B, C ] and later we would like to add devices with identifiers [ D, E ].
In the second call, CLI should detect that LiveSync is already running and execute initial sync only for newly added devices. However the current check for unique device identifiers is not correct and it always returns empty array as we first add the new devices to the old ones and then compare the new array with the already modified old array of devices.
Check the difference before adding new device identifiers to the old ones.1 parent 00776b0 commit 70a6e17
1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
120 | 120 | | |
121 | 121 | | |
122 | 122 | | |
123 | | - | |
124 | 123 | | |
| 124 | + | |
125 | 125 | | |
| 126 | + | |
126 | 127 | | |
127 | 128 | | |
128 | 129 | | |
| |||
140 | 141 | | |
141 | 142 | | |
142 | 143 | | |
143 | | - | |
144 | 144 | | |
145 | 145 | | |
146 | 146 | | |
| |||
0 commit comments