Skip to content

Commit

Permalink
Move JSMin code to a separate package
Browse files Browse the repository at this point in the history
  • Loading branch information
slusarz authored and mrubinsk committed Nov 14, 2013
1 parent d5671c9 commit ce4736c
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 413 deletions.
12 changes: 7 additions & 5 deletions framework/Text_Filter/lib/Horde/Text/Filter/JavascriptMinify.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,14 @@ public function postProcess($text)
}

/* Use PHP-based minifier. */
$jsmin = new Horde_Text_Filter_JavascriptMinify_JsMin($text);
try {
return $jsmin->minify();
} catch (Exception $e) {
return $text;
if (class_exists('Horde_Text_Filter_Jsmin')) {
$jsmin = new Horde_Text_Filter_Jsmin($text);
try {
return $jsmin->minify();
} catch (Exception $e) {}
}

return $text;
}

/**
Expand Down
315 changes: 0 additions & 315 deletions framework/Text_Filter/lib/Horde/Text/Filter/JavascriptMinify/JsMin.php

This file was deleted.

0 comments on commit ce4736c

Please sign in to comment.