Make WordPress Core

Opened 8 years ago

Closed 7 years ago

#34956 closed defect (bug) (fixed)

The default for the `comment_post_ID` in `wp_insert_comment` should be `0` not an empty string

Reported by: rachelbaker's profile rachelbaker Owned by: rachelbaker's profile rachelbaker
Milestone: 4.5 Priority: normal
Severity: normal Version: 4.0
Component: Comments Keywords: needs-patch good-first-bug
Focuses: Cc:


The comment_post_ID column in the database is BIGINT and has a default value of 0. Introduced in r28457.

Attachments (3)

34956.diff (927 bytes) - added by MikeHansenMe 7 years ago.
34956-correct-spacing.diff (927 bytes) - added by juanfra 7 years ago.
Correct spacing after asignation
34956.2.diff (1.6 KB) - added by rabmalin 7 years ago.
default value changes and its doc modified accordingly

Download all attachments as: .zip

Change History (6)

#1 @rachelbaker
8 years ago

  • Milestone changed from Awaiting Review to 4.5

#2 @rachelbaker
7 years ago

  • Keywords needs-unit-tests removed

7 years ago

7 years ago

Correct spacing after asignation

7 years ago

default value changes and its doc modified accordingly

#3 @rachelbaker
7 years ago

  • Owner set to rachelbaker
  • Resolution set to fixed
  • Status changed from new to closed

In 35948:

Comments: Use an integer as the default value for comment_post_ID in wp_insert_comment to match database column.

Props MikeHansenMe, juanfra, rabmalin.
Fixes #34956

Note: See TracTickets for help on using tickets.