mirror of
https://we.phorge.it/source/phorge.git
synced 2025-01-30 16:38:21 +01:00
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
This commit is contained in:
parent
7af180348d
commit
9a9cb07d15
3 changed files with 6 additions and 2 deletions
|
@ -3561,12 +3561,13 @@ celerity_register_resource_map(array(
|
||||||
),
|
),
|
||||||
'phabricator-uiexample-javelin-view' =>
|
'phabricator-uiexample-javelin-view' =>
|
||||||
array(
|
array(
|
||||||
'uri' => '/res/2da87384/rsrc/js/application/uiexample/JavelinViewExample.js',
|
'uri' => '/res/d42834b6/rsrc/js/application/uiexample/JavelinViewExample.js',
|
||||||
'type' => 'js',
|
'type' => 'js',
|
||||||
'requires' =>
|
'requires' =>
|
||||||
array(
|
array(
|
||||||
0 => 'javelin-install',
|
0 => 'javelin-install',
|
||||||
1 => 'javelin-dom',
|
1 => 'javelin-dom',
|
||||||
|
2 => 'javelin-view',
|
||||||
),
|
),
|
||||||
'disk' => '/rsrc/js/application/uiexample/JavelinViewExample.js',
|
'disk' => '/rsrc/js/application/uiexample/JavelinViewExample.js',
|
||||||
),
|
),
|
||||||
|
|
|
@ -113,7 +113,9 @@ final class DarkConsoleCore {
|
||||||
* need to convert it to UTF-8.
|
* need to convert it to UTF-8.
|
||||||
*/
|
*/
|
||||||
private function sanitizeForJSON($data) {
|
private function sanitizeForJSON($data) {
|
||||||
if (is_array($data)) {
|
if (is_object($data)) {
|
||||||
|
return '<object:'.get_class($data).'>';
|
||||||
|
} else if (is_array($data)) {
|
||||||
foreach ($data as $key => $value) {
|
foreach ($data as $key => $value) {
|
||||||
$data[$key] = $this->sanitizeForJSON($value);
|
$data[$key] = $this->sanitizeForJSON($value);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
* @provides phabricator-uiexample-javelin-view
|
* @provides phabricator-uiexample-javelin-view
|
||||||
* @requires javelin-install
|
* @requires javelin-install
|
||||||
* javelin-dom
|
* javelin-dom
|
||||||
|
* javelin-view
|
||||||
*/
|
*/
|
||||||
|
|
||||||
JX.install('JavelinViewExample', {
|
JX.install('JavelinViewExample', {
|
||||||
|
|
Loading…
Add table
Reference in a new issue