Instead of using 0/1 being Disabled/Enabled, using boolean FALSE/TRUE would make more sense. This applies to pingback_hide_format_for_anon, pingback_receive, and pingback_notify_successful_pings.

Also, instead of using strings for pingback_mode, perhaps we could/should use 0/1/2 (using constants to make them human readable, of course)?

Comments

andreashaugstrup’s picture

I'm all for using integers for pingback_mode.

In regards to the enabled/disabled for the other values we should just do whatever drupal core does

Freso’s picture

Status: Active » Needs work
StatusFileSize
new1.95 KB

pingback_mode changed to use integers, not touched the FALSE/TRUE stuff yet.

Freso’s picture

Title: Reform site variable values » Site variable value reform

I should probably note that the above patch won't work, as it's only the admin interface that's been changed - places in the code that are using the setting haven't been updated, before I'm sure this is "more core" than what was there before. :)

Freso’s picture

Status: Needs work » Active

Alright, after a bit of ping-ponging with Morbus, the above patch is discarded, and we're now only working with changing 1/0 to TRUE/FALSE. :)

Freso’s picture

Status: Active » Needs review
StatusFileSize
new5.36 KB

So here's one with 1 -> TRUE and 0 -> FALSE.

dave reid’s picture

This doesn't make a lot of sense or value at all. Core uses 0/1 for radio and checkbox values just because that's what the Form API saves. Can we just mark this as closed?