Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F101695262
PhabricatorUserPHIDResolver.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
Wed, Feb 12, 20:22
Size
641 B
Mime Type
text/x-php
Expires
Fri, Feb 14, 20:22 (1 d, 20 h)
Engine
blob
Format
Raw Data
Handle
24213630
Attached To
rPH Phabricator
PhabricatorUserPHIDResolver.php
View Options
<?php
final
class
PhabricatorUserPHIDResolver
extends
PhabricatorPHIDResolver
{
protected
function
getResolutionMap
(
array
$names
)
{
// Pick up the normalization and case rules from the PHID type query.
foreach
(
$names
as
$key
=>
$name
)
{
$names
[
$key
]
=
'@'
.
$name
;
}
$query
=
id
(
new
PhabricatorObjectQuery
())
->
setViewer
(
$this
->
getViewer
());
$users
=
id
(
new
PhabricatorPeopleUserPHIDType
())
->
loadNamedObjects
(
$query
,
$names
);
$results
=
array
();
foreach
(
$users
as
$at_username
=>
$user
)
{
$results
[
substr
(
$at_username
,
1
)]
=
$user
->
getPHID
();
}
return
$results
;
}
}
Event Timeline
Log In to Comment