From c4a746c1bfcaf185f705d70fe441dd77af2c50ad Mon Sep 17 00:00:00 2001 From: Champ Camba Date: Tue, 24 Jan 2017 19:58:35 +0800 Subject: [PATCH] Remove notices --- core/um-fields.php | 2 +- core/um-short-functions.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/um-fields.php b/core/um-fields.php index 2a8fb690..4073e9bf 100644 --- a/core/um-fields.php +++ b/core/um-fields.php @@ -1113,7 +1113,7 @@ class UM_Fields { $disabled = ' disabled="disabled" '; - if ( $data['public'] == '-2' && $data['roles'] ){ + if ( isset( $data['public'] ) && $data['public'] == '-2' && $data['roles'] ){ if ( in_array( $ultimatemember->query->get_role_by_userid( get_current_user_id() ), $data['roles'] ) ){ $disabled = ''; } diff --git a/core/um-short-functions.php b/core/um-short-functions.php index b680ef40..1dcab326 100644 --- a/core/um-short-functions.php +++ b/core/um-short-functions.php @@ -1056,7 +1056,7 @@ if ( is_user_logged_in() && isset( $data['editable'] ) && $data['editable'] == 0 ) { - if( $data['public'] == "-2"){ + if( isset( $data['public'] ) && $data['public'] == "-2"){ return true; }