Skip to content

Linking.openUrl with a telephone number throws an error #26554

Closed
@andrewsouthard

Description

React Native version:
System:
OS: macOS Mojave 10.14.6
CPU: (4) x64 Intel(R) Core(TM) i5-5257U CPU @ 2.70GHz
Memory: 37.91 MB / 8.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 12.4.0 - ~/.nvm/versions/node/v12.4.0/bin/node
Yarn: 1.12.1 - ~/.yarn/bin/yarn
npm: 6.9.0 - ~/.nvm/versions/node/v12.4.0/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
iOS SDK:
Platforms: iOS 12.4, macOS 10.14, tvOS 12.4, watchOS 5.3
Android SDK:
API Levels: 27, 28
Build Tools: 27.0.3, 28.0.0, 28.0.2, 28.0.3
System Images: android-28 | Google Play Intel x86 Atom
IDEs:
Android Studio: 3.5 AI-191.8026.42.35.5791312
Xcode: 10.3/10G8 - /usr/bin/xcodebuild
npmPackages:
react: 16.9.0 => 16.9.0
react-native: 0.61.0 => 0.61.0

Steps To Reproduce

  1. react-native init phonetest
  2. Change App.js to the following:
import {Button, Linking, SafeAreaView} from 'react-native';

const App = () => {
  return (
    <SafeAreaView>
      <Button
        onPress={() => {
          Linking.openURL('tel:555-867-5309').catch(err =>
            console.error('An error occurred', err),
          );
        }}
        title="Call"
      />
    </SafeAreaView>
  );
};

export default App;
  1. react-native run-ios

Describe what you expected to happen:
Dialog box asking whether to call the number or cancel

Instead, received the following error:
Simulator Screen Shot - iPhone X - 2019-09-24 at 16 04 12

Metadata

Assignees

No one assigned

    Labels

    API: LinkingBugGood first issueInterested in collaborating? Take a stab at fixing one of these issues.Resolution: LockedThis issue was locked by the bot.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions