summaryrefslogtreecommitdiffstats
path: root/app/views
diff options
context:
space:
mode:
authorMarius Balteanu <marius.balteanu@zitec.com>2022-02-18 08:08:10 +0000
committerMarius Balteanu <marius.balteanu@zitec.com>2022-02-18 08:08:10 +0000
commit9f822657820fb87675698d9e6151e7dc650e099f (patch)
tree3967c16c095e04a24650e535a41699a69d14e091 /app/views
parentd8263dcdee13b27ea4ac56c28d10dc2ca7fb8b40 (diff)
downloadredmine-9f822657820fb87675698d9e6151e7dc650e099f.tar.gz
redmine-9f822657820fb87675698d9e6151e7dc650e099f.zip
Fix WikiContentVersion API returns 500 if author is nil (#36494).
git-svn-id: http://svn.redmine.org/redmine/trunk@21414 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views')
-rw-r--r--app/views/wiki/show.api.rsb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/views/wiki/show.api.rsb b/app/views/wiki/show.api.rsb
index 8e082e123..6165a94cc 100644
--- a/app/views/wiki/show.api.rsb
+++ b/app/views/wiki/show.api.rsb
@@ -5,7 +5,7 @@ api.wiki_page do
end
api.text @content.text
api.version @content.version
- api.author(:id => @content.author_id, :name => @content.author.name)
+ api.author(:id => @content.author_id, :name => @content.author.name) unless @content.author_id.nil?
api.comments @content.comments
api.created_on @page.created_on
api.updated_on @content.updated_on