Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F98280069
ConduitTokenGarbageCollector.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, Jan 11, 17:50
Size
453 B
Mime Type
text/x-php
Expires
Mon, Jan 13, 17:50 (2 d)
Engine
blob
Format
Raw Data
Handle
23548601
Attached To
rPH Phabricator
ConduitTokenGarbageCollector.php
View Options
<?php
final
class
ConduitTokenGarbageCollector
extends
PhabricatorGarbageCollector
{
public
function
collectGarbage
()
{
$table
=
new
PhabricatorConduitToken
();
$conn_w
=
$table
->
establishConnection
(
'w'
);
queryfx
(
$conn_w
,
'DELETE FROM %T WHERE expires <= %d
ORDER BY dateCreated ASC LIMIT 100'
,
$table
->
getTableName
(),
PhabricatorTime
::
getNow
());
return
(
$conn_w
->
getAffectedRows
()
==
100
);
}
}
Event Timeline
Log In to Comment