fix fatal #49

Merged
lemsmyth merged 16 commits from rebased-from-lbryio-master into master 2022-02-12 21:02:53 +01:00
Showing only changes of commit 87a0c132fa - Show all commits

View file

@ -25,7 +25,7 @@ class LBRY_Admin
*/ */
public function create_options_page() public function create_options_page()
{ {
$hook_suffix = add_menu_page( add_menu_page(
__('LBRYPress Settings', 'lbrypress'), __('LBRYPress Settings', 'lbrypress'),
__('LBRYPress', 'lbrypress'), __('LBRYPress', 'lbrypress'),
'manage_options', 'manage_options',
@ -50,6 +50,17 @@ class LBRY_Admin
add_action( 'admin_enqueue_scripts', 'load_admin_stylesheet' ); add_action( 'admin_enqueue_scripts', 'load_admin_stylesheet' );
} }
/**
* Returns the Options Page HTML for the plugin
*/
public function options_page_html()
{
// Set class properties to be referenced in callbacks
$this->options = get_option( LBRY_SETTINGS );
$this->options_speech = get_option( LBRY_SPEECH_SETTINGS );
require_once( LBRY_ABSPATH . 'templates/options-page.php' );
}
/** /**
* Registers all settings for the plugin * Registers all settings for the plugin
*/ */
@ -146,17 +157,6 @@ class LBRY_Admin
); );
} }
/**
* Returns the Options Page HTML for the plugin
*/
public function options_page_html()
{
// Set class property to be referenced in callbacks
$this->options = get_option(LBRY_SETTINGS);
require_once( LBRY_ABSPATH . 'templates/options-page.php' );
}
/** /**
* Sanitizes setting input * Sanitizes setting input
* // COMBAK Potentially sanitize more * // COMBAK Potentially sanitize more
@ -341,7 +341,6 @@ class LBRY_Admin
); );
} }
/** /**
* Handles new channel form submission * Handles new channel form submission
*/ */