Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F98572157
DarkConsoleEventPluginAPI.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Tue, Jan 14, 11:27
Size
536 B
Mime Type
text/x-php
Expires
Thu, Jan 16, 11:27 (2 d)
Engine
blob
Format
Raw Data
Handle
23577791
Attached To
rPH Phabricator
DarkConsoleEventPluginAPI.php
View Options
<?php
final
class
DarkConsoleEventPluginAPI
extends
PhabricatorEventListener
{
private
static
$events
=
array
();
private
static
$discardMode
=
false
;
public
static
function
enableDiscardMode
()
{
self
::
$discardMode
=
true
;
}
public
static
function
getEvents
()
{
return
self
::
$events
;
}
public
function
register
()
{
$this
->
listen
(
PhabricatorEventType
::
TYPE_ALL
);
}
public
function
handleEvent
(
PhutilEvent
$event
)
{
if
(
self
::
$discardMode
)
{
return
;
}
self
::
$events
[]
=
$event
;
}
}
Event Timeline
Log In to Comment