--- beautify.install copy	2009-01-09 15:47:02.000000000 -0800
+++ beautify.install	2009-02-09 11:58:19.000000000 -0800
@@ -4,26 +4,25 @@
  * Implementation of hook_requirements().
  */
 function beautify_requirements($phase) {
-  $requirements = array();
-  $t = get_t();
-  switch ($phase) {
-    case 'runtime':
-      if (!beautify_htmltidy_test($message, $version)) {
-        $requirements['beautify_htmltidy'] = array(
-          'title' => $t('HTML Tidy'),
-          'description' => $t('Download and install the HTML Tidy binary <a href="http://tidy.sourceforge.net/">http://tidy.sourceforge.net/</a>'),
-          'severity' => $phase == 'install' ? REQUIREMENT_WARNING : REQUIREMENT_ERROR,
-          'value' => $t('Tidy binary not found.'),
-        );
-      }
-      else {
-        $requirements['beautify_htmltidy'] = array(
-          'title' => $t('HTML Tidy'),
-          'severity' => REQUIREMENT_OK,
-          'value' => $t('HTMLTidy was found <code>%tidy_version</code>', array('%tidy_version' => $version)),
-        );
-      }
-    break;
-  }
-  return $requirements;
+	if ($phase === 'runtime' && variable_get('beautify_method', 'builtin') === 'htmltidy') {
+		if (!beautify_htmltidy_test($message, $version)) {
+		  return array(
+		  	'beautify_htmltidy' => array(
+			    'title' => t('HTML Tidy'),
+			    'description' => t('Download and install the HTML Tidy binary at <a href="http://tidy.sourceforge.net/">http://tidy.sourceforge.net/</a>'),
+			    'severity' => REQUIREMENT_ERROR,
+			    'value' => t('Tidy binary not found.'),
+			  ),
+		  );
+		}
+		else {
+		  return array(
+		  	'beautify_htmltidy' => array(
+			    'title' => t('HTML Tidy'),
+			    'severity' => REQUIREMENT_OK,
+			    'value' => t('HTMLTidy was found: <code>%tidy_version</code>', array('%tidy_version' => $version)),
+			  ),
+		  );
+	  }
+	}
 }
