fix issue with trying to call is_active on objects w/o method

This commit is contained in:
John Bintz 2009-12-20 22:55:18 -05:00
parent 657080c990
commit 3e84f9d36b
1 changed files with 5 additions and 3 deletions

View File

@ -29,8 +29,10 @@ function __comicpress_widgets_init() {
if ($type != 'wp_inactive_widgets') {
foreach ($widgets as $widget_id) {
foreach ($available_widgets as $key => $widget) {
if (strpos(strtolower($widget_id), $key) === 0) {
$widget->is_active();
if (method_exists($widget, 'is_active')) {
if (strpos(strtolower($widget_id), $key) === 0) {
$widget->is_active();
}
}
}
}
@ -191,7 +193,7 @@ function comicpress_load_options() {
'enable_comicpress_debug' => true,
'enable_full_post_check' => false,
'enable_blogroll_off_links' => false
) as $field => $value) {