mirror of
https://github.com/10h30/ultimatemember.git
synced 2026-06-05 15:09:37 +09:00
- fixed editable attribute base on the legacy code;
- if `editable` attribute doesn't exist then we set `editable` to true by default;
This commit is contained in:
@@ -1065,7 +1065,8 @@ if ( ! class_exists( 'um\core\Form' ) ) {
|
||||
if ( strstr( $field_key, 'role_' ) && array_key_exists( 'options', $field_settings ) && is_array( $field_settings['options'] ) ) {
|
||||
|
||||
if ( isset( $this->post_form['mode'] ) && 'profile' === $this->post_form['mode'] ) {
|
||||
if ( empty( $field_settings['editable'] ) || ! um_can_edit_field( $field_settings ) ) {
|
||||
// It's for a legacy case `array_key_exists( 'editable', $field_settings )`.
|
||||
if ( ( array_key_exists( 'editable', $field_settings ) && empty( $field_settings['editable'] ) ) || ! um_can_edit_field( $field_settings ) ) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user