From 7bc966032bf74aa2f134014bdd0551a0eadcddc2 Mon Sep 17 00:00:00 2001 From: Juergen Hoeller Date: Tue, 29 Jul 2014 11:42:29 +0200 Subject: [PATCH] Rearranged statement whitespace in Velocity macros --- .../web/servlet/view/velocity/spring.vm | 23 ++++++++----------- 1 file changed, 10 insertions(+), 13 deletions(-) diff --git a/spring-webmvc/src/main/java/org/springframework/web/servlet/view/velocity/spring.vm b/spring-webmvc/src/main/java/org/springframework/web/servlet/view/velocity/spring.vm index e7de71e9d46..9064115ee17 100644 --- a/spring-webmvc/src/main/java/org/springframework/web/servlet/view/velocity/spring.vm +++ b/spring-webmvc/src/main/java/org/springframework/web/servlet/view/velocity/spring.vm @@ -82,7 +82,7 @@ * by user config. *# #macro( springBind $path ) - #if ("$!springHtmlEscape" != "") + #if("$!springHtmlEscape"!="") #set( $status = $springMacroRequestContext.getBindStatus($path, $springHtmlEscape) ) #else #set( $status = $springMacroRequestContext.getBindStatus($path) ) @@ -171,7 +171,7 @@ * from a list of options. * * The null check for $status.value leverages Velocity's 'quiet' notation rather - * than the more common #if ($status.value) since this method evaluates to the + * than the more common #if($status.value) since this method evaluates to the * boolean 'false' if the content of $status.value is the String "false" - not * what we want. * @@ -185,7 +185,7 @@ @@ -208,7 +208,7 @@ #foreach($option in $options.keySet()) #end @@ -231,7 +231,7 @@ #springBind($path) #foreach($option in $options.keySet()) - + #end #** @@ -293,10 +293,10 @@ *# #macro( springShowErrors $separator $classOrStyle ) #foreach($error in $status.errorMessages) - #if ($classOrStyle == "") + #if($classOrStyle=="") ${error} #else - #if ($classOrStyle.indexOf(":") == -1) + #if($classOrStyle.indexOf(":")==-1) #set($attr="class") #else #set($attr="style") @@ -314,9 +314,6 @@ * depending on the value of a 'springXhtmlCompliant' variable in the * template context. *# -#macro( springCloseTag )#if ($springXhtmlCompliant)/>#else>#end #end +#macro( springCloseTag )#if($springXhtmlCompliant)/>#else>#end#end #macro( springXmlId $id)#if($id)$id.replaceAll("\[","").replaceAll("\]","")#else$id#end#end - - -