Completed
Push — v3-ssp ( bdeb17...167089 )
by Sam
01:48
created

UpdateAddonsCron::getSchedule()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
1
0 ignored issues
show
Security Bug introduced by
It is not recommended to output anything before PHP's opening tag in non-template files.
Loading history...
2
<?php
3
4
class UpdateAddonsCron implements CronTask
5
{
6
7
    /**
8
     * Run hourly, on the 30min mark
9
     *
10
     * @return string
11
     */
12
    public function getSchedule()
13
    {
14
        return "30 * * * *";
15
    }
16
17
    /**
18
     * Run the build task UpdateAddonsTask
19
     * @return void
20
     */
21
    public function process() {
22
        $task = Injector::inst()->get('UpdateAddonsTask');
23
        $task->run(new SS_HTTPRequest('GET', '/'));
24
    }
25
}
26