function biblio_admin_dir_layout_check in Bibliography Module 6.2
Checks on structure of include files for biblio module.
1 call to biblio_admin_dir_layout_check()
- biblio_admin_settings in includes/
biblio.admin.inc - Implements hook_settings().
File
- includes/
biblio.admin.inc, line 42 - Administrative files for the biblio module.
Code
function biblio_admin_dir_layout_check() {
$dir = drupal_get_path('module', 'biblio');
$files = file_scan_directory($dir, '..*.inc$', array(
'.',
'..',
), 0, FALSE);
if (count($files)) {
$message = t('There is a problem with your Biblio installation! There should not be any ".inc" files in the %biblio directory. You probably forgot to delete the old biblio files when you upgraded the module. You should remove the following files from that directory...', array(
'%biblio' => $dir,
));
$message .= "<ul>";
foreach ($files as $file) {
$message .= "<li>" . $file->basename . "</li>";
}
$message .= "</ul>";
drupal_set_message($message, 'error');
// @todo: Log this list to the watchdog table as well?
}
}