Deal with style= single valued parameter

This commit is contained in:
Dave Syer
2013-08-19 17:21:45 +01:00
parent 8a137b6646
commit 6667b4dbd3

View File

@@ -100,6 +100,9 @@ class MainController {
if (style==null || style.size()==0) {
style = [""]
}
if (!style.class.isArray() && !(style instanceof Collection)) {
style = [style]
}
model["styles"] = style.collect{ it=="" ? "" : "-" + it }
log.info("Model: " + model)