mirror of
https://github.com/ad-aures/castopod.git
synced 2026-04-13 03:27:45 +02:00
style(ecs): add easy-coding-standard to enforce coding style rules for php
- update .devcontainer settings: remove auto-formatting for php + set intelephense as default formatter - remove prettier php plugin as it lacks php 8 support - add captain hook action for checking style pre-commit - fix style with ecs on all files except views
This commit is contained in:
parent
fb3593f828
commit
aa1612342e
230 changed files with 3420 additions and 5884 deletions
|
|
@ -1,8 +1,7 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* This class defines the Object which is the
|
||||
* primary base type for the Activity Streams vocabulary.
|
||||
* This class defines the Object which is the primary base type for the Activity Streams vocabulary.
|
||||
*
|
||||
* Object is a reserved word in php, so the class is named ObjectType.
|
||||
*
|
||||
|
|
@ -13,14 +12,17 @@
|
|||
|
||||
namespace ActivityPub\Objects;
|
||||
|
||||
use ActivityPub\Entities\Note;
|
||||
use ActivityPub\Core\ObjectType;
|
||||
use ActivityPub\Entities\Note;
|
||||
|
||||
class NoteObject extends ObjectType
|
||||
{
|
||||
protected string $type = 'Note';
|
||||
|
||||
protected string $attributedTo;
|
||||
|
||||
protected string $inReplyTo;
|
||||
|
||||
protected string $replies;
|
||||
|
||||
public function __construct(Note $note)
|
||||
|
|
@ -35,9 +37,7 @@ class NoteObject extends ObjectType
|
|||
$this->inReplyTo = $note->reply_to_note->uri;
|
||||
}
|
||||
|
||||
$this->replies = base_url(
|
||||
route_to('note-replies', $note->actor->username, $note->id),
|
||||
);
|
||||
$this->replies = base_url(route_to('note-replies', $note->actor->username, $note->id),);
|
||||
|
||||
$this->cc = [$note->actor->followers_url];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue