mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-18 19:40:55 +01:00
Improve error handling for Aphlict.
Summary: Currently, any error thrown when instantiating an `AphlictMaster` will be assumed to be due to the master already existing. This is a bit overzealous because the [[http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/net/LocalConnection.html#connect() | documentation]] specifically states than an `ArgumentError` will be throw if "the `LocalConnection` instance is already connected". Test Plan: Inspected the log message. Reviewers: epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: epriestley, Korvin Differential Revision: https://secure.phabricator.com/D9422
This commit is contained in:
parent
c5ee3a4522
commit
7d255aedba
3 changed files with 19 additions and 18 deletions
|
@ -8,7 +8,7 @@ return array(
|
|||
'names' =>
|
||||
array(
|
||||
'core.pkg.css' => '703a28a5',
|
||||
'core.pkg.js' => '9c9c8442',
|
||||
'core.pkg.js' => '5f0169b1',
|
||||
'darkconsole.pkg.js' => 'ca8671ce',
|
||||
'differential.pkg.css' => '4a93db37',
|
||||
'differential.pkg.js' => 'eca39a2c',
|
||||
|
@ -337,7 +337,7 @@ return array(
|
|||
'rsrc/image/texture/table_header_tall.png' => 'd56b434f',
|
||||
'rsrc/js/application/aphlict/Aphlict.js' => '493665ee',
|
||||
'rsrc/js/application/aphlict/behavior-aphlict-dropdown.js' => '2a2dba85',
|
||||
'rsrc/js/application/aphlict/behavior-aphlict-listen.js' => '258e4342',
|
||||
'rsrc/js/application/aphlict/behavior-aphlict-listen.js' => '130086a6',
|
||||
'rsrc/js/application/auth/behavior-persona-login.js' => '9414ff18',
|
||||
'rsrc/js/application/config/behavior-reorder-fields.js' => '938aed89',
|
||||
'rsrc/js/application/conpherence/behavior-menu.js' => '7ee23816',
|
||||
|
@ -477,7 +477,7 @@ return array(
|
|||
'rsrc/js/phuix/PHUIXActionListView.js' => 'b5c256b8',
|
||||
'rsrc/js/phuix/PHUIXActionView.js' => '6e8cefa4',
|
||||
'rsrc/js/phuix/PHUIXDropdownMenu.js' => 'bd4c8dca',
|
||||
'rsrc/swf/aphlict.swf' => '2816ec25',
|
||||
'rsrc/swf/aphlict.swf' => 'b7c2d7aa',
|
||||
),
|
||||
'symbols' =>
|
||||
array(
|
||||
|
@ -528,7 +528,7 @@ return array(
|
|||
'javelin-aphlict' => '493665ee',
|
||||
'javelin-behavior' => '8a3ed18b',
|
||||
'javelin-behavior-aphlict-dropdown' => '2a2dba85',
|
||||
'javelin-behavior-aphlict-listen' => '258e4342',
|
||||
'javelin-behavior-aphlict-listen' => '130086a6',
|
||||
'javelin-behavior-aphront-basic-tokenizer' => 'b3a4b884',
|
||||
'javelin-behavior-aphront-crop' => 'b98fc918',
|
||||
'javelin-behavior-aphront-drag-and-drop-textarea' => '4a11ea9c',
|
||||
|
@ -917,6 +917,18 @@ return array(
|
|||
4 => 'javelin-util',
|
||||
5 => 'phabricator-shaped-request',
|
||||
),
|
||||
'130086a6' =>
|
||||
array(
|
||||
0 => 'javelin-behavior',
|
||||
1 => 'javelin-aphlict',
|
||||
2 => 'javelin-stratcom',
|
||||
3 => 'javelin-request',
|
||||
4 => 'javelin-uri',
|
||||
5 => 'javelin-dom',
|
||||
6 => 'javelin-json',
|
||||
7 => 'javelin-router',
|
||||
8 => 'phabricator-notification',
|
||||
),
|
||||
'1681c4d4' =>
|
||||
array(
|
||||
0 => 'javelin-install',
|
||||
|
@ -995,18 +1007,6 @@ return array(
|
|||
2 => 'javelin-stratcom',
|
||||
3 => 'phuix-dropdown-menu',
|
||||
),
|
||||
'258e4342' =>
|
||||
array(
|
||||
0 => 'javelin-behavior',
|
||||
1 => 'javelin-aphlict',
|
||||
2 => 'javelin-stratcom',
|
||||
3 => 'javelin-request',
|
||||
4 => 'javelin-uri',
|
||||
5 => 'javelin-dom',
|
||||
6 => 'javelin-json',
|
||||
7 => 'javelin-router',
|
||||
8 => 'phabricator-notification',
|
||||
),
|
||||
'263aeb8c' =>
|
||||
array(
|
||||
0 => 'javelin-behavior',
|
||||
|
|
|
@ -80,9 +80,10 @@ package {
|
|||
this.log('Attempting to become the master...');
|
||||
this.master = new AphlictMaster(this.remoteServer, this.remotePort);
|
||||
this.log('I am the master.');
|
||||
} catch (x:Error) {
|
||||
// Couldn't become the master
|
||||
} catch (err:ArgumentError) {
|
||||
this.log('Cannot become the master... probably one already exists');
|
||||
} catch (err:Error) {
|
||||
this.error(err);
|
||||
}
|
||||
|
||||
this.send.send('aphlict_master', 'register', this.client);
|
||||
|
|
Binary file not shown.
Loading…
Reference in a new issue