Completed
Push — 2.10 ( a4add1 )
by Marcus
8s
created
code/forms/GridFieldQueuedJobExecute.php 1 patch
Doc Comments   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,6 +33,9 @@  discard block
 block discarded – undo
33 33
 	 */
34 34
 	protected $viewCheck;
35 35
 
36
+	/**
37
+	 * @param Closure $check
38
+	 */
36 39
 	public function __construct($action = 'execute', $check = null) {
37 40
 		$this->action = $action;
38 41
 		if (!$check) {
@@ -85,7 +88,7 @@  discard block
 block discarded – undo
85 88
 	 * Which columns are handled by this component
86 89
 	 *
87 90
 	 * @param type $gridField
88
-	 * @return type
91
+	 * @return string[]
89 92
 	 */
90 93
 	public function getColumnsHandled($gridField) {
91 94
 		return array('Actions');
@@ -95,7 +98,7 @@  discard block
 block discarded – undo
95 98
 	 * Which GridField actions are this component handling
96 99
 	 *
97 100
 	 * @param GridField $gridField
98
-	 * @return array
101
+	 * @return string[]
99 102
 	 */
100 103
 	public function getActions($gridField) {
101 104
 		return array('execute', 'pause', 'resume');
Please login to merge, or discard this patch.
code/services/DefaultQueueHandler.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -11,6 +11,9 @@
 block discarded – undo
11 11
 		$job->activateOnQueue();
12 12
 	}
13 13
 
14
+	/**
15
+	 * @param Date $date
16
+	 */
14 17
 	public function scheduleJob(QueuedJobDescriptor $job, $date) {
15 18
 		// noop
16 19
 	}
Please login to merge, or discard this patch.
code/tasks/engines/BaseRunner.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
 	/**
38 38
 	 * Logs the status of the queued job descriptor.
39 39
 	 *
40
-	 * @param bool|null|QueuedJobDescriptor $descriptor
40
+	 * @param DataObject|null $descriptor
41 41
 	 * @param string $queue
42 42
 	 */
43 43
 	protected function logDescriptorStatus($descriptor, $queue) {
Please login to merge, or discard this patch.
code/tasks/engines/DoormanRunner.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
 	}
23 23
 
24 24
 	/**
25
-	 * @return array List of rules
25
+	 * @return string List of rules
26 26
 	 */
27 27
 	public function getDefaultRules() {
28 28
 		return $this->defaultRules;
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
 
67 67
 	/**
68 68
 	 * @param string $queue
69
-	 * @return null|QueuedJobDescriptor
69
+	 * @return DataObject|null
70 70
 	 */
71 71
 	protected function getNextJobDescriptorWithoutMutex($queue) {
72 72
 		$list = QueuedJobDescriptor::get()
Please login to merge, or discard this patch.
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -1,7 +1,5 @@
 block discarded – undo
1 1
 <?php
2 2
 
3
-use AsyncPHP\Doorman\Rule;
4
-
5 3
 /**
6 4
  * Runs all jobs through the doorman engine
7 5
  */
Please login to merge, or discard this patch.
code/services/QueuedJobService.php 1 patch
Doc Comments   +6 added lines, -3 removed lines patch added patch discarded remove patch
@@ -156,7 +156,7 @@  discard block
 block discarded – undo
156 156
 	/**
157 157
 	 * Start a job (or however the queue handler determines it should be started)
158 158
 	 *
159
-	 * @param JobDescriptor $jobDescriptor
159
+	 * @param QueuedJobDescriptor $jobDescriptor
160 160
 	 * @param date $startAfter
161 161
 	 */
162 162
 	public function startJob($jobDescriptor, $startAfter = null) {
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
 	 * Copies data from a job into a descriptor for persisting
173 173
 	 *
174 174
 	 * @param QueuedJob $job
175
-	 * @param JobDescriptor $jobDescriptor
175
+	 * @param DataObject $jobDescriptor
176 176
 	 */
177 177
 	protected function copyJobToDescriptor($job, $jobDescriptor) {
178 178
 		$data = $job->getJobData();
@@ -318,7 +318,7 @@  discard block
 block discarded – undo
318 318
 	 * Attempt to restart a stalled job
319 319
 	 *
320 320
 	 * @param QueuedJobDescriptor $stalledJob
321
-	 * @return bool True if the job was successfully restarted
321
+	 * @return boolean|null True if the job was successfully restarted
322 322
 	 */
323 323
 	protected function restartStalledJob($stalledJob) {
324 324
 		if ($stalledJob->ResumeCounts < Config::inst()->get(__CLASS__, 'stall_threshold')) {
@@ -728,6 +728,9 @@  discard block
 block discarded – undo
728 728
 		}
729 729
 	}
730 730
 
731
+	/**
732
+	 * @param double $size
733
+	 */
731 734
 	protected function humanReadable($size) {
732 735
 		$filesizename = array(" Bytes", " KB", " MB", " GB", " TB", " PB", " EB", " ZB", " YB");
733 736
 		return $size ? round($size/pow(1024, ($i = floor(log($size, 1024)))), 2) . $filesizename[$i] : '0 Bytes';
Please login to merge, or discard this patch.