litesoft
Diff Revisions
404
vs
405
for /trunk/Java/VersionedStaticContentFilter/src/org/litesoft/servlet/versionedstaticcontentfilter/VersionedStaticContentFilter.java
|
@@ -254,7 +254,13 @@ |
254 |
254 |
|
@Override |
255 |
255 |
|
protected boolean shouldNotCache( String pRequestURI ) |
256 |
256 |
|
{ |
257 |
|
- |
return pRequestURI.endsWith( ".js" ) || pRequestURI.endsWith( ".css" ); |
|
257 |
+ |
int at = pRequestURI.lastIndexOf( '.' ); |
|
258 |
+ |
if ( at == -1 ) |
|
259 |
+ |
{ |
|
260 |
+ |
return false; // No '.' -> Always Cache! |
|
261 |
+ |
} |
|
262 |
+ |
String zExtension = pRequestURI.substring( at + 1 ); |
|
263 |
+ |
return "html".equalsIgnoreCase( zExtension ) || "js".equalsIgnoreCase( zExtension ) || "css".equalsIgnoreCase( zExtension ); |
258 |
264 |
|
} |
259 |
265 |
|
|
260 |
266 |
|
@Override |