Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F471002
AlmanacInterfaceDestroyTransaction.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
748 B
Referenced Files
None
Subscribers
None
AlmanacInterfaceDestroyTransaction.php
View Options
<?php
final
class
AlmanacInterfaceDestroyTransaction
extends
AlmanacInterfaceTransactionType
{
const
TRANSACTIONTYPE
=
'almanac:interface:destroy'
;
public
function
generateOldValue
(
$object
)
{
return
false
;
}
public
function
applyExternalEffects
(
$object
,
$value
)
{
id
(
new
PhabricatorDestructionEngine
())
->
destroyObject
(
$object
);
}
public
function
validateTransactions
(
$object
,
array
$xactions
)
{
$errors
=
array
();
if
(
$xactions
)
{
if
(
$object
->
loadIsInUse
())
{
$errors
[]
=
$this
->
newInvalidError
(
pht
(
'You can not delete this interface because it is currently in '
.
'use. One or more services are bound to it.'
));
}
}
return
$errors
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Tue, May 6, 12:54 PM (2 d)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
80001
Default Alt Text
AlmanacInterfaceDestroyTransaction.php (748 B)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment