Skip to content

Commit

Permalink
LPS-54998 - Cache result from PortalWebResourcesUtil
Browse files Browse the repository at this point in the history
  • Loading branch information
michael.bradford@liferay.com authored and brianchandotcom committed Apr 24, 2015
1 parent 16c6a8a commit 75e3e70
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions util-taglib/src/com/liferay/taglib/FileAvailabilityUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,6 @@ public static boolean isAvailable(
return true;
}

if (PortalWebResourcesUtil.isResourceAvailable(path)) {
return true;
}

Map<String, Boolean> availabilities = _getAvailabilities(
servletContext);

Expand All @@ -66,7 +62,9 @@ public static boolean isAvailable(
catch (Exception e) {
}

if (url == null) {
if ((url == null) &&
!PortalWebResourcesUtil.isResourceAvailable(path)) {

available = Boolean.FALSE;
}
else {
Expand Down

0 comments on commit 75e3e70

Please sign in to comment.