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

Prevent false mod_rewrite error

If Google's Closure Compiler API is enabled, rewriteTest.js is served as
"1;" instead of "1". Therefore the "Note: Your webserver does not seem
to support mod_rewrite (used in /min/.htaccess). Your Minify URIs will
contain '?', which may reduce the benefit of proxy cache servers." is
wrong. This is a simple workaround.
This commit is contained in:
Jonas Thelemann
2016-06-25 01:19:44 +02:00
parent 6a2995f932
commit b37d837ff9

View File

@@ -12,7 +12,7 @@ var MUB = {
$.ajax({ $.ajax({
url : '../f=' + testUri + '&' + (new Date()).getTime(), url : '../f=' + testUri + '&' + (new Date()).getTime(),
success : function (data) { success : function (data) {
if (data === '1') { if (data === '1' || data === '1;') {
MUB._minRoot = '/min/'; MUB._minRoot = '/min/';
$('span.minRoot').html('/min/'); $('span.minRoot').html('/min/');
} else } else