diff --git a/drools-core/src/main/java/org/drools/io/impl/UrlResource.java b/drools-core/src/main/java/org/drools/io/impl/UrlResource.java
index <HASH>..<HASH> 100644
--- a/drools-core/src/main/java/org/drools/io/impl/UrlResource.java
+++ b/drools-core/src/main/java/org/drools/io/impl/UrlResource.java
@@ -141,7 +141,7 @@ public class UrlResource extends BaseResource
                 if (cacheFileExists()) return fromCache();
             }
             if (lastMod > 0 && lastMod > lastRead) {
-                if (CACHE_DIR != null && url.getProtocol().equals("http") || url.getProtocol().equals("https")) {
+                if (CACHE_DIR != null && (url.getProtocol().equals("http") || url.getProtocol().equals("https"))) {
                     //lets grab a copy and cache it in case we need it in future...
                     cacheStream();
                 }
BZ<I>, DROOLS-<I> - fixing switch off URL caching issue
(cherry picked from commit 4bc1e<I>aa<I>c<I>f<I>c<I>e<I>e8fe<I>dbd<I>b)