Permalink
Browse files

Updated context path check to prevent 404 error in Grails 1.4 M1+

  • Loading branch information...
1 parent a9a5cad commit cecc688772a5dfa45e017fa3e56f79f3a28c73f2 @RGBz RGBz committed Dec 16, 2011
Showing with 5 additions and 1 deletion.
  1. +5 −1 grails-app/taglib/grails/lesscss/LessTagLib.groovy
@@ -113,7 +113,11 @@ class LessTagLib {
}
StringBuilder path = new StringBuilder()
- path << g.resource(plugin:plugin ?: null, contextPath: contextPath ?: '', dir: dir, file: name)
+ if(contextPath) {
+ path << g.resource(plugin:plugin ?: null, contextPath: contextPath ?: '', dir: dir, file: name)
+ } else {
+ path << g.resource(plugin:plugin ?: null, dir: dir, file: name)
+ }
if (extension) {
path << extension
}

0 comments on commit cecc688

Please sign in to comment.