Automattic / Automattic/co-authors-plus

If certain characters exist in the name, display_name is set to empty string

Open
#647 1 comment 0 reactions 0 assignees View on GitHub
status: needs investigation
Dominant language
PHP
Stars
322
Forks
218
Avg merge
7h 50m
Merged PRs (30d)
65

Description

I am adding authors using command line (wp cli) and few authors have following characters (é, ç, etc) in their name. It throws an exception. **Note that I modified some code to check what the error is**

![image](https://user-images.githubusercontent.com/41803529/52974126-7a324c00-338e-11e9-8107-58812233983d.png)

sanitize_text_field() is returning an empty string for names with those characters.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the author-creation path through WP-CLI with names containing characters such as é and ç, then inspect where sanitize_text_field() is called and where display_name becomes empty. Confirm the exception and compare behavior with names using basic characters; done means accented author names retain a non-empty display_name without throwing an exception.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, wordpress
Domain
backend, cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.