Subversion-Projekte lars-tiefland.laravel_shop

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
402 lars 1
<?php
2
 
3
namespace Illuminate\Queue\Middleware;
4
 
5
class SkipIfBatchCancelled
6
{
7
    /**
8
     * Process the job.
9
     *
10
     * @param  mixed  $job
11
     * @param  callable  $next
12
     * @return mixed
13
     */
14
    public function handle($job, $next)
15
    {
16
        if (method_exists($job, 'batch') && $job->batch()?->cancelled()) {
17
            return;
18
        }
19
 
20
        $next($job);
21
    }
22
}