summaryrefslogtreecommitdiff
path: root/modules/comment/controllers/comments.php
diff options
context:
space:
mode:
Diffstat (limited to 'modules/comment/controllers/comments.php')
-rw-r--r--modules/comment/controllers/comments.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/comment/controllers/comments.php b/modules/comment/controllers/comments.php
index 989ad177..8b2e5155 100644
--- a/modules/comment/controllers/comments.php
+++ b/modules/comment/controllers/comments.php
@@ -62,7 +62,8 @@ class Comments_Controller extends REST_Controller {
* @see Rest_Controller::_show($resource)
*/
public function _show($comment) {
- switch (rest::output_format()) {
+ $output_format = rest::output_format();
+ switch ($output_format) {
case "xml":
rest::http_content_type(rest::XML);
print xml::to_xml($comment->as_array(), array("comment"));