From 9a9cb07d15265e7cb3b2724bab772b134db889f1 Mon Sep 17 00:00:00 2001 From: epriestley Date: Tue, 16 Jul 2013 13:35:25 -0700 Subject: [PATCH] Fix more JavelinView example stuff Summary: Fixes T3544. Depends on D6475. This was just a missing dependency combined with some questionable error handling which I'll maybe fix some day. Test Plan: Loaded page, saw result. Reviewers: btrahan Reviewed By: btrahan CC: aran Maniphest Tasks: T3544 Differential Revision: https://secure.phabricator.com/D6476 --- src/__celerity_resource_map__.php | 3 ++- src/aphront/console/DarkConsoleCore.php | 4 +++- webroot/rsrc/js/application/uiexample/JavelinViewExample.js | 1 + 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/__celerity_resource_map__.php b/src/__celerity_resource_map__.php index dac3902315..0e1a717a47 100644 --- a/src/__celerity_resource_map__.php +++ b/src/__celerity_resource_map__.php @@ -3561,12 +3561,13 @@ celerity_register_resource_map(array( ), 'phabricator-uiexample-javelin-view' => array( - 'uri' => '/res/2da87384/rsrc/js/application/uiexample/JavelinViewExample.js', + 'uri' => '/res/d42834b6/rsrc/js/application/uiexample/JavelinViewExample.js', 'type' => 'js', 'requires' => array( 0 => 'javelin-install', 1 => 'javelin-dom', + 2 => 'javelin-view', ), 'disk' => '/rsrc/js/application/uiexample/JavelinViewExample.js', ), diff --git a/src/aphront/console/DarkConsoleCore.php b/src/aphront/console/DarkConsoleCore.php index d72026af5a..36598026b5 100644 --- a/src/aphront/console/DarkConsoleCore.php +++ b/src/aphront/console/DarkConsoleCore.php @@ -113,7 +113,9 @@ final class DarkConsoleCore { * need to convert it to UTF-8. */ private function sanitizeForJSON($data) { - if (is_array($data)) { + if (is_object($data)) { + return ''; + } else if (is_array($data)) { foreach ($data as $key => $value) { $data[$key] = $this->sanitizeForJSON($value); } diff --git a/webroot/rsrc/js/application/uiexample/JavelinViewExample.js b/webroot/rsrc/js/application/uiexample/JavelinViewExample.js index 7967e20c8c..a8e17923b2 100644 --- a/webroot/rsrc/js/application/uiexample/JavelinViewExample.js +++ b/webroot/rsrc/js/application/uiexample/JavelinViewExample.js @@ -2,6 +2,7 @@ * @provides phabricator-uiexample-javelin-view * @requires javelin-install * javelin-dom + * javelin-view */ JX.install('JavelinViewExample', {