Skip to content

Commit 18dc25e

Browse files
authored
Issue-15061 Grails-doc bug in render example (#15072)
The code example in the documentation did not work.
1 parent 2960324 commit 18dc25e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

grails-doc/src/en/ref/Controllers/render.adoc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,13 @@ render {
6363
}
6464
6565
// render some XML markup to the response
66+
def bookList = [
67+
new Book(title: 'The Shining', author: 'Stephen King'),
68+
new Book(title: 'The Great Gatsby', author: 'F. Scott Fitzgerald')
69+
]
6670
render(contentType: "text/xml") {
6771
books {
68-
for (b in books) {
72+
for (b in bookList) {
6973
book(title: b.title, author: b.author)
7074
}
7175
}

0 commit comments

Comments
 (0)