Bug 1802889 Comment 6 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

There are two things I've added in my patch:

- The observers for when FxA devices are connected/disconnected were not added/removed as part of this update: https://phabricator.services.mozilla.com/D153069. Those have now been added.
- When a mobile device is the only synced device beyond the current one (desktop) and you remove the current device (desktop), then sign back in from Fx View Tab Pickup banner, `fxAccounts.device.recentDeviceList` only returns the mobile device for some reason (possibly due to device cache). This causes our checks for a secondary device to fail (as we now only have access to the mobile device from `recentDeviceList`, and we're assuming the one device we DO have access to is our current device - which is not the case). This is why Tab Pickup was incorrectly displaying the mobile promo "Connect a mobile device" message. I've added a check at the start of `refreshDevices()` to manually refresh the device list (ignoring device cache) if the `recentDeviceList` doesn't contain a device with `isCurrentDevice` set to true. This is really a workaround for the caching stuff going on behind the scenes, but this does seem to fix things from our end.

Update: This appears to happen when any second device is connected, even a second desktop. This workaround seems to fix bug 1804363 also.
There are two things I've added in my patch:

- The observers for when FxA devices are connected/disconnected were not added/removed as part of this update: https://phabricator.services.mozilla.com/D153069. Those have now been added.
- When a mobile device is the only synced device beyond the current one (desktop) and you remove the current device (desktop), then sign back in from Fx View Tab Pickup banner, `fxAccounts.device.recentDeviceList` only returns the mobile device for some reason (possibly due to device cache). This causes our checks for a secondary device to fail (as we now only have access to the mobile device from `recentDeviceList`, and we're assuming the one device we DO have access to is our current device - which is not the case). This is why Tab Pickup was incorrectly displaying the  "Connect a mobile device" message. I've added a check at the start of `refreshDevices()` to manually refresh the device list (ignoring device cache) if the `recentDeviceList` doesn't contain a device with `isCurrentDevice` set to true. This is really a workaround for the caching stuff going on behind the scenes, but this does seem to fix things from our end.

Update: This appears to happen when any second device is connected, even a second desktop. This workaround seems to fix bug 1804363 also.
There are two things I've added in my patch:

- The observers for when FxA devices are connected/disconnected were not added/removed as part of this update: https://phabricator.services.mozilla.com/D153069. Those have now been added.
- When a mobile device is the only synced device beyond the current one (desktop) and you remove the current device (desktop), then sign back in from Fx View Tab Pickup banner, `fxAccounts.device.recentDeviceList` only returns the mobile device for some reason (possibly due to device cache). This causes our checks for a secondary device to fail (as we now only have access to the mobile device from `recentDeviceList`, and we're assuming the one device we DO have access to is our current device - which is not the case). This is why Tab Pickup was incorrectly displaying the  "Sync Firefox on your phone or tablet" message. I've added a check at the start of `refreshDevices()` to manually refresh the device list (ignoring device cache) if the `recentDeviceList` doesn't contain a device with `isCurrentDevice` set to true. This is really a workaround for the caching stuff going on behind the scenes, but this does seem to fix things from our end.

Update: This appears to happen when any second device is connected, even a second desktop. This workaround seems to fix bug 1804363 also.

Back to Bug 1802889 Comment 6