I tried disabling the plugins (but it worked earlier anyway), switching to the twentytwenty theme and renaming bp-custom.php, and it did not work. My workaround: create a new search form, add all fields, publish, delete the old form which I wanted to change. For now it is OK this way.
The question for debugging is: where does “message 4” come from? I found this place:
bps-start.php
add_filter ('post_updated_messages', 'bps_updated_messages');
function bps_updated_messages ($messages)
{
$messages['bps_form'] = array
(
0 => 'message 0',
1 => __('Form updated.', 'bp-profile-search'),
2 => 'message 2',
3 => 'message 3',
4 => 'message 4',
5 => 'message 5',
6 => __('Form created.', 'bp-profile-search'),
7 => 'message 7',
8 => 'message 8',
9 => 'message 9',
10 => __('Form draft updated.', 'bp-profile-search'),
);
return $messages;
}