EscolaLMS/Webinar

View on GitHub
Fix images (#73) #212
Witold Wiśniewski authored 7ec6ede7
complete00:00:30
Your first build completed successfully!

Congratulations

Your first build completed successfully!

See the Results

1
git clone
2
codeclimate validate-config
View output
codeclimate validate-config
No errors or warnings found in .codeclimate.json.
3
codeclimate prepare
View output
codeclimate prepare
4
builder pull-engines
View output
determining required images
docker pull codeclimate/codeclimate-phan:b885
b885: Pulling from codeclimate/codeclimate-phan
8e402f1a9c57: Pulling fs layer
abc2d0fc5668: Pulling fs layer
dc541c3b1e49: Pulling fs layer
9f6ca43a9b11: Pulling fs layer
c7737daaa88e: Pulling fs layer
dacca831c5b2: Pulling fs layer
16fbe636fb42: Pulling fs layer
723d37ca9d09: Pulling fs layer
9eddffd41f08: Pulling fs layer
fb7a0bf324fd: Pulling fs layer
d45ca5424117: Pulling fs layer
9f6ca43a9b11: Waiting
c7737daaa88e: Waiting
dacca831c5b2: Waiting
16fbe636fb42: Waiting
723d37ca9d09: Waiting
9eddffd41f08: Waiting
fb7a0bf324fd: Waiting
d45ca5424117: Waiting
abc2d0fc5668: Verifying Checksum
abc2d0fc5668: Download complete
8e402f1a9c57: Download complete
dc541c3b1e49: Download complete
8e402f1a9c57: Pull complete
dacca831c5b2: Download complete
abc2d0fc5668: Pull complete
c7737daaa88e: Verifying Checksum
c7737daaa88e: Download complete
dc541c3b1e49: Pull complete
16fbe636fb42: Verifying Checksum
16fbe636fb42: Download complete
9f6ca43a9b11: Verifying Checksum
9f6ca43a9b11: Download complete
723d37ca9d09: Download complete
fb7a0bf324fd: Verifying Checksum
fb7a0bf324fd: Download complete
d45ca5424117: Verifying Checksum
d45ca5424117: Download complete
9eddffd41f08: Download complete
9f6ca43a9b11: Pull complete
c7737daaa88e: Pull complete
dacca831c5b2: Pull complete
16fbe636fb42: Pull complete
723d37ca9d09: Pull complete
9eddffd41f08: Pull complete
fb7a0bf324fd: Pull complete
d45ca5424117: Pull complete
Digest: sha256:80f9f90a9dc7ed88b958d04b86493d2a7bff8f1bdf1ba775c0c9ba6e254f6181
Status: Downloaded newer image for registry.prod.codeclimate.net/codeclimate/codeclimate-phan:b885
docker pull codeclimate/codeclimate-phpcodesniffer:b163
b163: Pulling from codeclimate/codeclimate-phpcodesniffer
a0710691c81a: Pulling fs layer
a3ed95caeb02: Pulling fs layer
f3c17b6c6935: Pulling fs layer
c3166a36a8d9: Pulling fs layer
83a051f0858f: Pulling fs layer
f0e9f15ec462: Pulling fs layer
034c114563b8: Pulling fs layer
5edc25e33d4e: Pulling fs layer
83a051f0858f: Waiting
c3166a36a8d9: Waiting
034c114563b8: Waiting
f0e9f15ec462: Waiting
5edc25e33d4e: Waiting
f3c17b6c6935: Verifying Checksum
f3c17b6c6935: Download complete
a3ed95caeb02: Verifying Checksum
a3ed95caeb02: Download complete
a0710691c81a: Verifying Checksum
a0710691c81a: Download complete
a0710691c81a: Pull complete
c3166a36a8d9: Verifying Checksum
c3166a36a8d9: Download complete
83a051f0858f: Download complete
a3ed95caeb02: Pull complete
f0e9f15ec462: Verifying Checksum
f0e9f15ec462: Download complete
034c114563b8: Verifying Checksum
034c114563b8: Download complete
f3c17b6c6935: Pull complete
5edc25e33d4e: Verifying Checksum
5edc25e33d4e: Download complete
c3166a36a8d9: Pull complete
83a051f0858f: Pull complete
f0e9f15ec462: Pull complete
034c114563b8: Pull complete
5edc25e33d4e: Pull complete
Digest: sha256:cab8fcc753b6ae0e309b899665b22b1b62c26c56dab9b3c6a938fa72ca7c0640
Status: Downloaded newer image for registry.prod.codeclimate.net/codeclimate/codeclimate-phpcodesniffer:b163
docker pull codeclimate/codeclimate-phpmd:b291
b291: Pulling from codeclimate/codeclimate-phpmd
41dcc117e123: Pulling fs layer
e7cb8c1bd7da: Pulling fs layer
382dd9e936d2: Pulling fs layer
01d3fd4ccf07: Pulling fs layer
d54cbc0233c4: Pulling fs layer
a01b3d804127: Pulling fs layer
02aaff91dfc2: Pulling fs layer
25d9a4b72163: Pulling fs layer
378b764b6ee5: Pulling fs layer
d8ae1ee899c7: Pulling fs layer
f11257bedacf: Pulling fs layer
01d3fd4ccf07: Waiting
40adf26d4529: Pulling fs layer
d54cbc0233c4: Waiting
02aaff91dfc2: Waiting
a01b3d804127: Waiting
25d9a4b72163: Waiting
f11257bedacf: Waiting
40adf26d4529: Waiting
378b764b6ee5: Waiting
d8ae1ee899c7: Waiting
382dd9e936d2: Download complete
e7cb8c1bd7da: Verifying Checksum
e7cb8c1bd7da: Download complete
41dcc117e123: Verifying Checksum
41dcc117e123: Download complete
41dcc117e123: Pull complete
a01b3d804127: Download complete
01d3fd4ccf07: Verifying Checksum
01d3fd4ccf07: Download complete
d54cbc0233c4: Verifying Checksum
d54cbc0233c4: Download complete
e7cb8c1bd7da: Pull complete
382dd9e936d2: Pull complete
25d9a4b72163: Verifying Checksum
25d9a4b72163: Download complete
02aaff91dfc2: Download complete
378b764b6ee5: Verifying Checksum
378b764b6ee5: Download complete
01d3fd4ccf07: Pull complete
d8ae1ee899c7: Download complete
f11257bedacf: Download complete
40adf26d4529: Verifying Checksum
40adf26d4529: Download complete
d54cbc0233c4: Pull complete
a01b3d804127: Pull complete
02aaff91dfc2: Pull complete
25d9a4b72163: Pull complete
378b764b6ee5: Pull complete
d8ae1ee899c7: Pull complete
f11257bedacf: Pull complete
40adf26d4529: Pull complete
Digest: sha256:100ad83154de1d7143edb4360753a5a3c2c35f8a0fd8f00352718003e2b63bfa
Status: Downloaded newer image for registry.prod.codeclimate.net/codeclimate/codeclimate-phpmd:b291
docker pull codeclimate/codeclimate-sonar-php:b23
b23: Pulling from codeclimate/codeclimate-sonar-php
97518928ae5f: Pulling fs layer
043df9f67e9a: Pulling fs layer
a42e650909d2: Pulling fs layer
0dff3d7a1a0e: Pulling fs layer
e109c25d106c: Pulling fs layer
b2fb00c172a9: Pulling fs layer
1519b1438731: Pulling fs layer
cfbd8af1af7a: Pulling fs layer
ea3b98fb78f4: Pulling fs layer
1c654bf89a09: Pulling fs layer
0dff3d7a1a0e: Waiting
e109c25d106c: Waiting
cfbd8af1af7a: Waiting
b2fb00c172a9: Waiting
ea3b98fb78f4: Waiting
1519b1438731: Waiting
1c654bf89a09: Waiting
97518928ae5f: Verifying Checksum
97518928ae5f: Download complete
a42e650909d2: Verifying Checksum
a42e650909d2: Download complete
97518928ae5f: Pull complete
e109c25d106c: Verifying Checksum
e109c25d106c: Download complete
b2fb00c172a9: Verifying Checksum
b2fb00c172a9: Download complete
0dff3d7a1a0e: Verifying Checksum
0dff3d7a1a0e: Download complete
043df9f67e9a: Verifying Checksum
043df9f67e9a: Download complete
cfbd8af1af7a: Verifying Checksum
cfbd8af1af7a: Download complete
1519b1438731: Verifying Checksum
1519b1438731: Download complete
ea3b98fb78f4: Verifying Checksum
ea3b98fb78f4: Download complete
043df9f67e9a: Pull complete
a42e650909d2: Pull complete
1c654bf89a09: Verifying Checksum
1c654bf89a09: Download complete
0dff3d7a1a0e: Pull complete
e109c25d106c: Pull complete
b2fb00c172a9: Pull complete
1519b1438731: Pull complete
cfbd8af1af7a: Pull complete
ea3b98fb78f4: Pull complete
1c654bf89a09: Pull complete
Digest: sha256:600639355d67f629857951762cd4d8d2bc9eb16a0496c67a3d6049830edcc87b
Status: Downloaded newer image for registry.prod.codeclimate.net/codeclimate/codeclimate-sonar-php:b23
5
structure
View output
12
Parser process id: 12
codeclimate-parser socket not present
waiting 1s...
6
duplication
View output
12
Parser process id: 12
codeclimate-parser socket not present
waiting 1s...
7
phan
phan engine documentation
8
phpcodesniffer
phpcodesniffer engine documentation
9
phpmd
phpmd engine documentation
10
sonar-php
sonar-php engine documentation
View output
INFO: Java 1.8.0_322 Amazon.com Inc. (64-bit)
INFO: Linux 4.4.0-1128-aws amd64
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/usr/src/app/build/libs/sonarlint-core-2.17.0.899.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/usr/src/app/build/libs/sonarlint-cli-2.1.0.566.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [ch.qos.logback.classic.util.ContextSelectorStaticBinder]
INFO: Index files
INFO: Invalid character encountered in file '/code/docs/menu.png' at line 1 for encoding UTF-8. Please fix file content or configure the encoding to be used using property 'sonar.sourceEncoding'.
INFO: Invalid character encountered in file '/code/docs/new_webinar.png' at line 1 for encoding UTF-8. Please fix file content or configure the encoding to be used using property 'sonar.sourceEncoding'.
INFO: Invalid character encountered in file '/code/docs/list.png' at line 1 for encoding UTF-8. Please fix file content or configure the encoding to be used using property 'sonar.sourceEncoding'.
INFO: 90 files indexed
INFO: 71 source files to be analyzed
ERROR: Unable to parse file: /code/src/Jobs/ReminderAboutWebinarJob.php
ERROR: Parse error at line 15 column 13:

 5: use EscolaLms\Webinar\Services\Contracts\WebinarServiceContract;
 6: use Illuminate\Bus\Queueable;
 7: use Illuminate\Contracts\Queue\ShouldQueue;
 8: use Illuminate\Foundation\Bus\Dispatchable;
 9: use Illuminate\Queue\InteractsWithQueue;
10: use Illuminate\Queue\SerializesModels;
11: 
12: class ReminderAboutWebinarJob implements ShouldQueue
13: {
14:     use Dispatchable, InteractsWithQueue, Queueable, SerializesModels;
15:     private string $status;
                ^
16: 
17:     /**
18:      * Create a new job instance.
19:      *
20:      * @return void
21:      */
22:     public function __construct(string $status)
23:     {
24:         $this->status = $status;
25:     }

ERROR: Unable to parse file: /code/src/Services/WebinarService.php
ERROR: Parse error at line 31 column 13:

21: use EscolaLms\Youtube\Dto\YTBroadcastDto;
22: use EscolaLms\Youtube\Enum\YTStatusesEnum;
23: use EscolaLms\Youtube\Exceptions\YtAuthenticateException;
24: use EscolaLms\Youtube\Services\Contracts\YoutubeServiceContract;
25: use Illuminate\Database\Eloquent\Builder;
26: use Illuminate\Support\Facades\DB;
27: use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
28: 
29: class WebinarService implements WebinarServiceContract
30: {
31:     private WebinarRepositoryContract $webinarRepositoryContract;
                ^
32:     private JitsiServiceContract $jitsiServiceContract;
33:     private YoutubeServiceContract $youtubeServiceContract;
34: 
35:     public function __construct(
36:         WebinarRepositoryContract $webinarRepositoryContract,
37:         JitsiServiceContract      $jitsiServiceContract,
38:         YoutubeServiceContract    $youtubeServiceContract
39:     )
40:     {
41:         $this->webinarRepositoryContract = $webinarRepositoryContract;

ERROR: Unable to parse file: /code/src/Http/Controllers/WebinarController.php
ERROR: Parse error at line 26 column 13:

16: use EscolaLms\Webinar\Http\Controllers\Swagger\WebinarSwagger;
17: use EscolaLms\Core\Http\Controllers\EscolaLmsBaseController;
18: use EscolaLms\Webinar\Http\Requests\ListWebinarsRequest;
19: use EscolaLms\Webinar\Http\Requests\WebinarAssignableUserListRequest;
20: use EscolaLms\Webinar\Http\Resources\WebinarSimpleResource;
21: use EscolaLms\Webinar\Services\Contracts\WebinarServiceContract;
22: use Illuminate\Http\JsonResponse;
23: 
24: class WebinarController extends EscolaLmsBaseController implements WebinarSwagger
25: {
26:     private WebinarServiceContract $webinarServiceContract;
                ^
27:     private UserServiceContract $userService;
28: 
29:     public function __construct(
30:         WebinarServiceContract $webinarServiceContract,
31:         UserServiceContract $userService
32:     ) {
33:         $this->webinarServiceContract = $webinarServiceContract;
34:         $this->userService = $userService;
35:     }
36: 

ERROR: Unable to parse file: /code/src/Http/Controllers/WebinarAPIController.php
ERROR: Parse error at line 16 column 13:

 6: use EscolaLms\Core\Http\Controllers\EscolaLmsBaseController;
 7: use EscolaLms\Webinar\Enum\ConstantEnum;
 8: use EscolaLms\Webinar\Http\Controllers\Swagger\WebinarAPISwagger;
 9: use EscolaLms\Webinar\Http\Requests\ListWebinarsRequest;
10: use EscolaLms\Webinar\Http\Resources\WebinarSimpleResource;
11: use EscolaLms\Webinar\Services\Contracts\WebinarServiceContract;
12: use Illuminate\Http\JsonResponse;
13: 
14: class WebinarAPIController extends EscolaLmsBaseController implements WebinarAPISwagger
15: {
16:     private WebinarServiceContract $webinarServiceContract;
                ^
17: 
18:     public function __construct(
19:         WebinarServiceContract $webinarServiceContract
20:     ) {
21:         $this->webinarServiceContract = $webinarServiceContract;
22:     }
23: 
24:     public function index(ListWebinarsRequest $listWebinarsRequest): JsonResponse
25:     {
26:         $search = $listWebinarsRequest->except(['limit', 'skip', 'order', 'order_by']);

ERROR: Unable to parse file: /code/src/Helpers/StrategyHelper.php
ERROR: Parse error at line 7 column 13:

 1: <?php
 2: 
 3: namespace EscolaLms\Webinar\Helpers;
 4: 
 5: class StrategyHelper
 6: {
 7:     private string $namespace;
                ^
 8: 
 9:     public function __construct(string $baseStrategyName)
10:     {
11:         $this->setNamespace($baseStrategyName);
12:     }
13: 
14:     /**
15:      * This method used strategy pattern and execute method given in the parameters
16:      * Strategy dir it must contain minimum to file: BaseStrategy contain in pattern {{parentDir}}Strategy
17:      * in localization ?/Strategies/{{parentDir}} and strategy class in the same localization

ERROR: Unable to parse file: /code/src/Repositories/Criteria/WebinarIncomingCriterion.php
ERROR: Parse error at line 11 column 13:

 1: <?php
 2: 
 3: namespace EscolaLms\Webinar\Repositories\Criteria;
 4: 
 5: use EscolaLms\Core\Repositories\Criteria\Criterion;
 6: use Illuminate\Database\Eloquent\Builder;
 7: use Illuminate\Support\Facades\DB;
 8: 
 9: class WebinarIncomingCriterion extends Criterion
10: {
11:     private ?bool $withDuration;
                ^
12:     public function __construct(string $value, ?bool $withDuration)
13:     {
14:         parent::__construct(null, $value);
15:         $this->withDuration = $withDuration;
16:     }
17: 
18:     public function apply(Builder $query): Builder
19:     {
20:         if ($this->withDuration) {
21:             return $query

ERROR: Unable to parse file: /code/src/Repositories/Criteria/WebinarTagsCriterion.php
ERROR: Parse error at line 18 column 53:

 8: 
 9: class WebinarTagsCriterion extends Criterion
10: {
11:     public function __construct($value = null)
12:     {
13:         parent::__construct(null, $value);
14:     }
15: 
16:     public function apply(Builder $query): Builder
17:     {
18:         return $query->whereHas('tags', fn (Builder $query) =>
                                                        ^
19:             $query->whereIn('title', $this->value)
20:         );
21:     }
22: }
23: 

ERROR: Unable to parse file: /code/src/Repositories/WebinarRepository.php
ERROR: Parse error at line 50 column 54:

40: 
41:     public function deleteModel(Webinar $webinar): ?bool
42:     {
43:         return $webinar->delete();
44:     }
45: 
46:     public function forCurrentUser(array $search = [], array $criteria = []): Builder
47:     {
48:         $q = $this->allQueryBuilder($search, $criteria);
49:         $q->where(function (Builder $query) {
50:             $query->orWhereHas('users', fn ($query) =>
                                                         ^
51:                 $query->where(['users.id' => auth()->user()->getKey()])
52:             );
53:             $query->orWhereHas('trainers', fn ($query) =>
54:                 $query->where(['users.id' => auth()->user()->getKey()])
55:             );
56:         });
57:         return $q;
58:     }
59: 
60:     public function getIncomingTerm(array $criteria = []): Collection

ERROR: Unable to parse file: /code/src/Dto/FilterListDto.php
ERROR: Parse error at line 20 column 13:

10: use EscolaLms\Webinar\Repositories\Criteria\WebinarIncomingCriterion;
11: use EscolaLms\Webinar\Repositories\Criteria\WebinarSearch;
12: use EscolaLms\Core\Repositories\Criteria\Primitives\DateCriterion;
13: use EscolaLms\Core\Repositories\Criteria\Primitives\EqualCriterion;
14: use EscolaLms\Core\Repositories\Criteria\Primitives\InCriterion;
15: use EscolaLms\Webinar\Repositories\Criteria\WebinarTagsCriterion;
16: use Illuminate\Database\Eloquent\Builder;
17: 
18: class FilterListDto extends BaseDto
19: {
20:     private string $name;
                ^
21:     private array $status;
22:     private array $reminderStatus;
23:     private string $dateTo;
24:     private string $dateFrom;
25:     private string $dateTimeTo;
26:     private string $dateTimeToLowerThan;
27:     private string $dateTimeFrom;
28:     private array $tags;
29: 
30:     private string $onlyIncoming;

ERROR: Unable to parse file: /code/src/Dto/WebinarDto.php
ERROR: Parse error at line 13 column 15:

 3: namespace EscolaLms\Webinar\Dto;
 4: 
 5: use Carbon\Carbon;
 6: use EscolaLms\Webinar\Dto\Contracts\ModelDtoContract;
 7: use EscolaLms\Webinar\Enum\ConstantEnum;
 8: use EscolaLms\Webinar\Models\Webinar;
 9: use Illuminate\Support\Str;
10: 
11: class WebinarDto extends BaseDto implements ModelDtoContract
12: {
13:     protected string $name;
                  ^
14:     protected string $status;
15:     protected string $description;
16:     protected string $shortDesc;
17:     protected string $agenda;
18:     protected ?string $activeTo;
19:     protected ?string $activeFrom;
20:     protected ?string $duration;
21:     protected ?int $basePrice;
22:     protected $imagePath = false;
23:     protected $logotypePath = false;

ERROR: Unable to parse file: /code/src/Dto/Traits/DtoHelper.php
ERROR: Parse error at line 9 column 15:

 1: <?php
 2: 
 3: namespace EscolaLms\Webinar\Dto\Traits;
 4: 
 5: use Illuminate\Support\Str;
 6: 
 7: trait DtoHelper
 8: {
 9:     protected array $relations = [];
                  ^
10:     protected array $files = [];
11: 
12:     protected function setterByData(array $data): void
13:     {
14:         foreach ($data as $k => $v) {
15:             $key = preg_replace_callback('/[_|-]([a-zA-Z])/', function ($match) {
16:                 return strtoupper($match[1]);
17:             }, $k);
18:             if (method_exists($this, 'set' . $key)) {
19:                 $this->{'set' . $key}($v);

ERROR: Unable to parse file: /code/src/Events/ReminderAboutTerm.php
ERROR: Parse error at line 10 column 13:

 1: <?php
 2: 
 3: namespace EscolaLms\Webinar\Events;
 4: 
 5: use EscolaLms\Core\Models\User;
 6: use EscolaLms\Webinar\Models\Webinar as WebinarModel;
 7: 
 8: class ReminderAboutTerm extends Webinar
 9: {
10:     private string $status;
                ^
11: 
12:     public function __construct(User $user, WebinarModel $webinar, string $status)
13:     {
14:         parent::__construct($user, $webinar);
15:         $this->status = $status;
16:     }
17: 
18:     public function getStatus()
19:     {
20:         return $this->status;

ERROR: Unable to parse file: /code/src/Events/Webinar.php
ERROR: Parse error at line 14 column 13:

 4: 
 5: use EscolaLms\Core\Models\User;
 6: use EscolaLms\Webinar\Models\Webinar as WebinarModel;
 7: use Illuminate\Foundation\Events\Dispatchable;
 8: use Illuminate\Queue\SerializesModels;
 9: 
10: abstract class Webinar
11: {
12:     use Dispatchable, SerializesModels;
13: 
14:     private User $user;
                ^
15:     private WebinarModel $webinar;
16: 
17:     public function __construct(User $user, WebinarModel $webinar)
18:     {
19:         $this->user = $user;
20:         $this->webinar = $webinar;
21:     }
22: 
23:     public function getUser(): User
24:     {

ERROR: Unable to parse file: /code/src/Listeners/ReminderAboutTermListener.php
ERROR: Parse error at line 10 column 13:

 1: <?php
 2: 
 3: namespace EscolaLms\Webinar\Listeners;
 4: 
 5: use EscolaLms\Webinar\Events\ReminderAboutTerm;
 6: use EscolaLms\Webinar\Services\Contracts\WebinarServiceContract;
 7: 
 8: class ReminderAboutTermListener
 9: {
10:     private WebinarServiceContract $webinarServiceContract;
                ^
11:     /**
12:      * Create the event listener.
13:      *
14:      * @return void
15:      */
16:     public function __construct(
17:         WebinarServiceContract $webinarServiceContract
18:     ) {
19:         $this->webinarServiceContract = $webinarServiceContract;
20:     }

ERROR: Unable to parse file: /code/src/Strategies/Relations/WebinarWithTagsStrategy.php
ERROR: Parse error at line 11 column 13:

 1: <?php
 2: 
 3: namespace EscolaLms\Webinar\Strategies\Relations;
 4: 
 5: use EscolaLms\Tags\Models\Tag;
 6: use EscolaLms\Webinar\Strategies\Contracts\RelationStrategyContract;
 7: use EscolaLms\Webinar\Models\Webinar;
 8: 
 9: class WebinarWithTagsStrategy implements RelationStrategyContract
10: {
11:     private Webinar $webinar;
                ^
12:     private array $data;
13: 
14:     public function __construct(array $params) {
15:         $this->webinar = $params[0];
16:         $this->data = $params[1] ?? [];
17:     }
18: 
19:     public function setRelation(): void
20:     {
21:         if (count($this->data['tags']) === 0) {

ERROR: Unable to parse file: /code/src/Strategies/Relations/WebinarWithTrainersStrategy.php
ERROR: Parse error at line 13 column 13:

 3: namespace EscolaLms\Webinar\Strategies\Relations;
 4: 
 5: use EscolaLms\Core\Models\User;
 6: use EscolaLms\Webinar\Events\WebinarTrainerAssigned;
 7: use EscolaLms\Webinar\Events\WebinarTrainerUnassigned;
 8: use EscolaLms\Webinar\Strategies\Contracts\RelationStrategyContract;
 9: use EscolaLms\Webinar\Models\Webinar;
10: 
11: class WebinarWithTrainersStrategy implements RelationStrategyContract
12: {
13:     private Webinar $webinar;
                ^
14:     private array $data;
15: 
16:     public function __construct(array $params) {
17:         $this->webinar = $params[0];
18:         $this->data = $params[1] ?? [];
19:     }
20: 
21:     public function setRelation(): void
22:     {
23:         $changes = $this->webinar->trainers()->sync($this->data['trainers']);

ERROR: Unable to parse file: /code/src/Strategies/Relations/RelationsStrategy.php
ERROR: Parse error at line 9 column 13:

 1: <?php
 2: 
 3: namespace EscolaLms\Webinar\Strategies\Relations;
 4: 
 5: use EscolaLms\Webinar\Strategies\Contracts\RelationStrategyContract;
 6: 
 7: class RelationsStrategy
 8: {
 9:     private RelationStrategyContract $relationStrategyContract;
                ^
10: 
11:     public function __construct(
12:         RelationStrategyContract $relationStrategyContract
13:     )
14:     {
15:         $this->relationStrategyContract = $relationStrategyContract;
16:     }
17: 
18:     public function setRelation(): void
19:     {

ERROR: Unable to parse file: /code/database/seeders/WebinarsSeeder.php
ERROR: Parse error at line 21 column 32:

11:     /**
12:      * Run the database seeds.
13:      *
14:      * @return void
15:      */
16:     public function run()
17:     {
18:         $users = User::factory(5)->create();
19:         Webinar::factory(10)
20:             ->create()
21:             ->each(fn (Webinar $webinar) =>
                                   ^
22:                 $webinar->users()->sync($users->pluck('id')->toArray())
23:             );
24:     }
25: }
26: 

INFO: 71/71 source files have been analyzed
INFO: ------------------------------------------------------------------------
INFO: EXECUTION SUCCESS
INFO: ------------------------------------------------------------------------
INFO: Total time: 0.798s
INFO: Final Memory: 11M/95M
INFO: ------------------------------------------------------------------------