Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F93618436
PhabricatorInvalidConfigSetupCheck.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
Sat, Nov 30, 05:03
Size
1 KB
Mime Type
text/x-php
Expires
Mon, Dec 2, 05:03 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
22677259
Attached To
rPH Phabricator
PhabricatorInvalidConfigSetupCheck.php
View Options
<?php
final
class
PhabricatorInvalidConfigSetupCheck
extends
PhabricatorSetupCheck
{
public
function
getDefaultGroup
()
{
return
self
::
GROUP_OTHER
;
}
protected
function
executeChecks
()
{
$groups
=
PhabricatorApplicationConfigOptions
::
loadAll
();
foreach
(
$groups
as
$group
)
{
$options
=
$group
->
getOptions
();
foreach
(
$options
as
$option
)
{
try
{
$group
->
validateOption
(
$option
,
PhabricatorEnv
::
getUnrepairedEnvConfig
(
$option
->
getKey
()));
}
catch
(
PhabricatorConfigValidationException
$ex
)
{
$this
->
newIssue
(
'config.invalid.'
.
$option
->
getKey
())
->
setName
(
pht
(
"Config '%s' Invalid"
,
$option
->
getKey
()))
->
setMessage
(
pht
(
"Configuration option '%s' has invalid value and "
.
"was restored to the default: %s"
,
$option
->
getKey
(),
$ex
->
getMessage
()))
->
addPhabricatorConfig
(
$option
->
getKey
());
}
}
}
}
}
Event Timeline
Log In to Comment