diff --git a/modules/blogapi.module b/modules/blogapi.module index 3498b9b99668d636375be0f9c280e75cefe53fcb..1b75cd5e94ac10b04c45ae16752804c29fa86c4e 100644 --- a/modules/blogapi.module +++ b/modules/blogapi.module @@ -723,7 +723,7 @@ function _blogapi_blogid($id) { } function _blogapi_get_node_types() { - $available_types = array_keys(variable_get('blogapi_node_types', array('blog' => 1)), 1); + $available_types = array_keys(array_filter(variable_get('blogapi_node_types', array('blog' => 1)))); $types = array(); foreach (node_get_types() as $type => $name) { if (node_access('create', $type) && in_array($type, $available_types)) { diff --git a/modules/blogapi/blogapi.module b/modules/blogapi/blogapi.module index 3498b9b99668d636375be0f9c280e75cefe53fcb..1b75cd5e94ac10b04c45ae16752804c29fa86c4e 100644 --- a/modules/blogapi/blogapi.module +++ b/modules/blogapi/blogapi.module @@ -723,7 +723,7 @@ function _blogapi_blogid($id) { } function _blogapi_get_node_types() { - $available_types = array_keys(variable_get('blogapi_node_types', array('blog' => 1)), 1); + $available_types = array_keys(array_filter(variable_get('blogapi_node_types', array('blog' => 1)))); $types = array(); foreach (node_get_types() as $type => $name) { if (node_access('create', $type) && in_array($type, $available_types)) {