Skip to content

Commit 3783e41

Browse files
Coding standards improvements
1 parent 6a5cad2 commit 3783e41

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

inc/class-mongoose-page-plugin.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -228,8 +228,8 @@ public function __construct() {
228228
* Setup dynamic properties.
229229
*/
230230
public function constants() {
231-
$this->dirurl = plugin_dir_url( dirname( __FILE__ ) );
232-
$this->dirpath = plugin_dir_path( dirname( __FILE__ ) );
231+
$this->dirurl = plugin_dir_url( __DIR__ );
232+
$this->dirpath = plugin_dir_path( __DIR__ );
233233
$this->basefile = plugin_basename( $this->dirpath . '/' . $this->slug . '.php' );
234234
$this->basename = basename( $this->dirpath );
235235
$this->settings_page_url = admin_url( 'options-general.php?page=' . $this->slug );
@@ -301,7 +301,7 @@ private function app_id() {
301301
public function donate_notice( $echo = false ) {
302302
$return = null;
303303

304-
if ( current_user_can( 'administrator' ) ) {
304+
if ( current_user_can( 'manage_options' ) ) {
305305
$user_id = get_current_user_id();
306306

307307
if ( ! get_user_meta( $user_id, $this->remove_donate_notice_key ) || get_user_meta( $user_id, $this->remove_donate_notice_key ) === false ) {
@@ -589,6 +589,4 @@ public function get_settings() {
589589
$return['tabs'] = array( 'timeline', 'events', 'messages' );
590590
return $return;
591591
}
592-
593592
}
594-

0 commit comments

Comments
 (0)