Skip to content

Commit

Permalink
Merge pull request #138 from jliszka/template_extension_fix2
Browse files Browse the repository at this point in the history
Don't add .mustache extension to template file name if it already has an extension
  • Loading branch information
capotej committed Oct 15, 2014
2 parents d8e3ec9 + a7e08ad commit e96008f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/scala/com/twitter/finatra/View.scala
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class FinatraMustacheFactory(baseTemplatePath:String) extends DefaultMustacheFac
// system and avoid using the classloader which has
// priority in DefaultMustacheFactory.getReader
else {
val fileName = if (resourceName contains ".mustache") resourceName else resourceName+".mustache"
val fileName = if (resourceName contains ".") resourceName else resourceName+".mustache"
val basePath = combinePaths(config.docRoot(), config.templatePath())
val file:File = new File(basePath, fileName)

Expand Down

0 comments on commit e96008f

Please sign in to comment.