HomePhabricator
Diffusion Comm 91ee903bac9d

[native] Fix server list in Dev tools menu

Description

[native] Fix server list in Dev tools menu

Summary:
On physical devices, the Profile -> Developer tools -> Server list was displaying the localhost as one of default options.

In url-utils.js, the server list was out of sync with rest of the code. It duplicated part of getDevServerHostname() logic, but it used the platform-specific localhost only.

Replaced the duplicated logic with getDevServerHostname() call.

Depends on D6268

Test Plan:
Opened the developer options on both simulator and physical device. Ensured that second option from the list is as follows:

  • On simulator it sticks to localhost / 10.0.2.2(Android)
  • On physical device it uses the autodetected IP address

Reviewers: ashoat, atul

Reviewed By: ashoat

Subscribers: tomek

Differential Revision: https://phab.comm.dev/D6269

Details

Provenance
bartekAuthored on Jan 14 2023, 8:23 AM
Reviewer
ashoat
Differential Revision
D6269: [native] Fix server list in Dev tools menu
Parents
rCOMMcc689095047a: [native] Default to 'natDevHostname' from expo config
Branches
Unknown
Tags
Unknown