I just ran into this issue while working on a module that creates its own fields.

I was testing the module by adding new fields through the fields ui but the fields were not being saved. I couldn't figure out why until I realized that an error message was being output but it was being added to the "message okay" box instead of the "message error" box.

It looks like the errors being output through drupal_set_message should have a $type property added.

#1 without patch.PNG43.24 KBDevin Carlson
#1 with patch.PNG44.74 KBDevin Carlson
#2 change-message-type-to-error-1308994-2.patch1.29 KBDevin Carlson
PASSED: [[SimpleTest]]: [MySQL] 33,320 pass(es). View
Members fund testing for the Drupal project. Drupal Association Learn more


Devin Carlson’s picture

44.74 KB
43.24 KB

Screenshots of what the errors look like currently and when set as warnings.

Devin Carlson’s picture

Status: Active » Needs review
1.29 KB
PASSED: [[SimpleTest]]: [MySQL] 33,320 pass(es). View

And a patch to add a type of 'error' to the messages I encountered.

droplet’s picture

Status: Needs review » Reviewed & tested by the community
yoroy’s picture

Issue tags: +Usability

Good catch, thanks for the screenshots.

Dries’s picture

Status: Reviewed & tested by the community » Fixed

Committed to 7.x and 8.x. Nice catch.

Automatically closed -- issue fixed for 2 weeks with no activity.