nextcloud / nextcloud/contacts
Import of a vCard version 4.0 doesn't interpret the phone number correctly
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 642
- Forks
- 220
- Avg merge
- 14h 39m
- Merged PRs (30d)
- 51
Description
Describe the bug
According to RFC 6350, the telephone item for version 4 of a vCard is specified as follows:
TEL;VALUE=uri;TYPE=home:tel:+33-01-23-45-67
However, when importing such an item in Nextcloud 30, the contact gets created with the telephone value of:
tel:+33-01-23-45-67
In my opinion, the "tel:" part needs to be stripped from the value while importing. It is just a hint of what type of URI the value is represented as.
Steps to reproduce
- Take a V4 vCard containing a telephone number in RFC conform format
- Import the card into an address book
- Open Contacts
- Select the newly imported contact
- notice the "Phone" section shows the wrong value prefixed by "tel:", in edit mode too
Expected behavior
The URI value should be correctly interpreted and the "tel:" prefix removed.
Actual behavior
The prefix "tel:" is treated as part of the phone number itself.
Contact version
7.0.0
Operating system
Rocky Linux 8
PHP engine version
PHP 8.2
Web server
Apache (supported)
Database
MySQL
Additional info
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No source file or test is named in the report; start by locating the vCard 4.0 import entry point and reproduce the RFC 6350 TEL example. Done means the imported phone value is shown without the tel: prefix, including in edit mode, with a regression test if the import tests are found.
Written by the indexing model from the issue text.
Assessment
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100