1
0
mirror of https://github.com/mrclay/minify.git synced 2025-08-12 09:05:08 +02:00

Created "min" = new default implementation as specified in Issue 45.

Minify: fixed default value in useServerCache(), + doc for 'contentType' serve() option
Minify_Controller_Base: added todo item
Minify_Controller_Version1: fixed default cache to '' (instead of null)
This commit is contained in:
Steve Clay
2008-08-12 01:55:35 +00:00
parent 1e04e2c68e
commit 961e04ca30
6 changed files with 139 additions and 2 deletions

View File

@@ -55,7 +55,7 @@ class Minify {
* @return null
* @deprecated
*/
public static function useServerCache($path = null)
public static function useServerCache($path = '')
{
self::setCache($path);
}
@@ -133,6 +133,11 @@ class Minify {
* $options['minifierOptions'][Minify::TYPE_CSS]['optionName'] = 'optionValue';
* </code>
*
* 'contentType' : (optional) this is only needed if your file extension is not
* js/css/html. The given content-type will be sent regardless of source file
* extension, so this should not be used in a Groups config with other
* Javascript/CSS files.
*
* Any controller options are documented in that controller's setupSources() method.
*
* @param mixed instance of subclass of Minify_Controller_Base or string name of
@@ -143,6 +148,8 @@ class Minify {
* @return mixed null, or, if the 'quiet' option is set to true, an array
* with keys "success" (bool), "statusCode" (int), "content" (string), and
* "headers" (array).
*
* @todo add option to auto-fix relative URIs in CSS (default = true)
*/
public static function serve($controller, $options = array()) {
if (is_string($controller)) {