Portale als Kacheln zeigen und Kalenderabrufe je Kanal protokollieren
Deploy FeWo mit PipelineManager / deploy (push) Successful in 2m41s
Deploy FeWo mit PipelineManager / deploy (push) Successful in 2m41s
This commit is contained in:
1 parent
98eabaeb0c
commit
511faa64d2
12 files changed
+337
-98
No files matched your search
@@ -23,14 +23,14 @@
|
||||
*/
|
||||
class ChannelController extends Controller
|
||||
{
|
||||
public function feed(string $token, ICalExport $feed): Response
|
||||
public function feed(string $token, ICalExport $feed, Request $request): Response
|
||||
{
|
||||
$channel = Channel::query()->where(fn ($query) => $query->where('export_token', $token)
|
||||
->orWhere(fn ($previous) => $previous->where('previous_export_token', $token)->where('previous_export_token_expires_at', '>', now())))->firstOrFail();
|
||||
|
||||
abort_unless($channel->servesItsLandlord(), 404);
|
||||
|
||||
$body = $feed->build($channel);
|
||||
$body = $feed->build($channel, $request->method(), $request->userAgent());
|
||||
if ($body === null) {
|
||||
return response('Der Export ist pausiert; es liegt noch kein gültiger Kalenderstand vor.', 503, ['Retry-After' => '300', 'Cache-Control' => 'no-store']);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user