Make WordPress Core

Opened 8 years ago

Last modified 6 months ago

#41631 new defect (bug)

Same Term Not Added

Reported by: vaprak's profile vaprak Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.8
Component: Taxonomy Keywords: dev-feedback needs-patch
Focuses: ui Cc:

Description

Using latest version of WordPress, default theme, all plugins disabled. Problem first appeared in version 4.8 and continues with 4.8.1.

To recreate the issue:

  1. Create regular post (“Posts”)
  2. Add a new term to the Categories meta box
  3. Save the term (it will appear on top of the list with a check mark next to it)
  4. Add the same term again. Nothing happens and the term is not added

Version 4.7.5 and below would activate the term and put to the top of list. This was helpful when adding a string of terms and some of them were already in the database.

Change History (2)

#1 @vaprak
8 years ago

  • Keywords dev-feedback added

Issue still exists in 4.8.2. Guess it's now expected behavior...

#2 @callumbw95
6 months ago

  • Focuses ui added
  • Keywords needs-patch added

Hi @vaprak,
I have taken a look into this in the latest release and can confirm that this is still occurring as you outlined previously in version 4.8. I have attached a bug report below outlining the steps I took, and hopefully we can get more conversation around this, and a potential fix. I will also have a look at getting a patch created for this shortly.

Bug Report

Description

When adding a duplicated category to a post there is no notification or confirmation that the term has been applied to the post.

Environment

  • WordPress: 6.9-alpha-60093-src
  • PHP: 8.4.7
  • Server: nginx/1.27.5
  • Database: mysqli (Server: 8.0.40 / Client: mysqlnd 8.4.7)
  • Browser: Chrome 137.0.0.0
  • OS: macOS
  • Theme: Twenty Seventeen 3.9
  • MU Plugins: None activated
  • Plugins:
    • Test Reports 1.2.0

Steps to Reproduce

  1. Create a new post.
  2. Add a new category term in sidebar, for example "test". This will be applied upon creation to the post.
  3. Create a second new category with the same term name.
  4. 🐞 Bug occurs, and whilst the term is technically applied, because it is the same as the previous term there is no confirmation of this happening, or a notice to say that a new term could not be created with the same name as an already existing term.

Expected Results

  1. If the term is applied to the post already the duplicated term should not be created and a notice saying that the term could not be created.
  2. If the term is not already attached to the post it should attach the correct term to the post.

Actual Results

  1. If the the term is applied to the post already nothing happens after submitting the duplicate term.
  2. If the term is not already attached to the post it should attach the correct term to the post.
Note: See TracTickets for help on using tickets.