@@ -16,7 +16,7 @@ discard block |
||
16 | 16 | */ |
17 | 17 | public function presenceRegister(PresenceRegistryRequest $request) |
18 | 18 | { |
19 | - if (! config('faithgen-sdk.source')) { |
|
19 | + if (!config('faithgen-sdk.source')) { |
|
20 | 20 | event(new UserPresent(auth('web')->user(), $request->validated())); |
21 | 21 | } |
22 | 22 | } |
@@ -28,7 +28,7 @@ discard block |
||
28 | 28 | */ |
29 | 29 | public function showTyping(PresenceRegistryRequest $request) |
30 | 30 | { |
31 | - if (! config('faithgen-sdk.source')) { |
|
31 | + if (!config('faithgen-sdk.source')) { |
|
32 | 32 | event(new TypingRegistered(auth('web')->user(), $request->validated())); |
33 | 33 | } |
34 | 34 | } |
@@ -26,7 +26,7 @@ |
||
26 | 26 | { |
27 | 27 | return [ |
28 | 28 | 'review' => 'required|string', |
29 | - 'type' => 'required|in:'.implode(',', Helper::$reviewTypes), |
|
29 | + 'type' => 'required|in:' . implode(',', Helper::$reviewTypes), |
|
30 | 30 | ]; |
31 | 31 | } |
32 | 32 | } |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | 'email' => 'required|email', |
30 | 30 | 'phone' => 'required', //todo write a regex to serve, |
31 | 31 | 'links' => 'array', |
32 | - 'color' => 'required|'.Helper::$hexColorRegex, |
|
32 | + 'color' => 'required|' . Helper::$hexColorRegex, |
|
33 | 33 | 'location' => 'array', |
34 | 34 | 'links.*' => 'url', |
35 | 35 | 'statement' => 'array', |
@@ -38,9 +38,9 @@ discard block |
||
38 | 38 | 'phones' => 'array', |
39 | 39 | 'emails.*' => 'email', |
40 | 40 | 'services' => 'array', |
41 | - 'services.*.day' => 'required|in:'.implode(',', Helper::$weekDays), |
|
42 | - 'services.*.start' => ['required', 'date_format:H:i', 'regex:/^((([01]?[0-9]|2[0-3]):[0-5][0-9])?)$/'], |
|
43 | - 'services.*.finish' => ['required', 'date_format:H:i', 'regex:/^((([01]?[0-9]|2[0-3]):[0-5][0-9])?)$/'], |
|
41 | + 'services.*.day' => 'required|in:' . implode(',', Helper::$weekDays), |
|
42 | + 'services.*.start' => [ 'required', 'date_format:H:i', 'regex:/^((([01]?[0-9]|2[0-3]):[0-5][0-9])?)$/' ], |
|
43 | + 'services.*.finish' => [ 'required', 'date_format:H:i', 'regex:/^((([01]?[0-9]|2[0-3]):[0-5][0-9])?)$/' ], |
|
44 | 44 | 'services.*.alias' => 'nullable', |
45 | 45 | ]; |
46 | 46 | } |
@@ -13,9 +13,9 @@ discard block |
||
13 | 13 | */ |
14 | 14 | public function search() |
15 | 15 | { |
16 | - return function ($attributes, ?string $filter_text) { |
|
16 | + return function($attributes, ?string $filter_text) { |
|
17 | 17 | if ($filter_text) { |
18 | - $filter_text = '%'.$filter_text.'%'; |
|
18 | + $filter_text = '%' . $filter_text . '%'; |
|
19 | 19 | } |
20 | 20 | |
21 | 21 | if (is_string($attributes)) { |
@@ -27,16 +27,16 @@ discard block |
||
27 | 27 | |
28 | 28 | $attribute = $attributes->first(); |
29 | 29 | |
30 | - $remainderKeys = $attributes->filter(fn ($field) => $field !== $attribute)->toArray(); |
|
30 | + $remainderKeys = $attributes->filter(fn($field) => $field !== $attribute)->toArray(); |
|
31 | 31 | |
32 | 32 | $query = $this->where($attribute, 'LIKE', $filter_text); |
33 | 33 | |
34 | 34 | if (count($remainderKeys)) { |
35 | 35 | foreach ($remainderKeys as $key) { |
36 | - if (! Str::of($key)->contains('.')) { |
|
36 | + if (!Str::of($key)->contains('.')) { |
|
37 | 37 | $query->orWhere($key, 'LIKE', $filter_text); |
38 | 38 | } else { |
39 | - [$relationship, $column] = explode('.', $key); |
|
39 | + [ $relationship, $column ] = explode('.', $key); |
|
40 | 40 | |
41 | 41 | // $eloquentBuilder->orWhereHas($relationship, fn($model) => $model->where($column, 'LIKE', $filter_text)); |
42 | 42 | } |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | */ |
35 | 35 | public function via($notifiable) |
36 | 36 | { |
37 | - return ['mail']; |
|
37 | + return [ 'mail' ]; |
|
38 | 38 | } |
39 | 39 | |
40 | 40 | /** |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | public function toMail($notifiable) |
47 | 47 | { |
48 | 48 | return (new MailMessage) |
49 | - ->greeting('Hello '.$this->ministry->name) |
|
49 | + ->greeting('Hello ' . $this->ministry->name) |
|
50 | 50 | ->line('You have requested for a password change, Please click the link below to update it!') |
51 | 51 | ->action('Reset Password', url('/')) |
52 | 52 | ->from('[email protected]', 'Faith Gen') |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | */ |
36 | 36 | public function via($notifiable) |
37 | 37 | { |
38 | - return ['mail']; |
|
38 | + return [ 'mail' ]; |
|
39 | 39 | } |
40 | 40 | |
41 | 41 | /** |
@@ -46,10 +46,10 @@ discard block |
||
46 | 46 | */ |
47 | 47 | public function toMail($notifiable) |
48 | 48 | { |
49 | - $url = url('/auth/activate/'.$this->ministry->id.'/'.$this->ministry->activation->code); |
|
49 | + $url = url('/auth/activate/' . $this->ministry->id . '/' . $this->ministry->activation->code); |
|
50 | 50 | |
51 | 51 | return (new MailMessage) |
52 | - ->greeting('Hello '.$this->ministry->name) |
|
52 | + ->greeting('Hello ' . $this->ministry->name) |
|
53 | 53 | ->subject('FaithGen account created!') |
54 | 54 | ->from('[email protected]', 'Faith Gen') |
55 | 55 | ->line('We have received your account registration request, please just activate your account to get started with us') |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | */ |
36 | 36 | public function via($notifiable) |
37 | 37 | { |
38 | - return ['mail']; |
|
38 | + return [ 'mail' ]; |
|
39 | 39 | } |
40 | 40 | |
41 | 41 | /** |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | public function toMail($notifiable) |
48 | 48 | { |
49 | 49 | return (new MailMessage) |
50 | - ->greeting('Hello '.$this->ministry->name) |
|
50 | + ->greeting('Hello ' . $this->ministry->name) |
|
51 | 51 | ->subject('Account activated') |
52 | 52 | ->line('Your FaithGen account has been activated.') |
53 | 53 | ->line('Please feel free to use our platform and always contact support if you miss something.') |
@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | * |
13 | 13 | * @var array |
14 | 14 | */ |
15 | - protected $policies = []; |
|
15 | + protected $policies = [ ]; |
|
16 | 16 | |
17 | 17 | /** |
18 | 18 | * Register services. |
@@ -36,12 +36,12 @@ discard block |
||
36 | 36 | Auth::guard('web')->loginUsingId($user_id); |
37 | 37 | } |
38 | 38 | |
39 | - if (! config('faithgen-sdk.source')) { |
|
40 | - Auth::viaRequest('api-key', function ($request) { |
|
39 | + if (!config('faithgen-sdk.source')) { |
|
40 | + Auth::viaRequest('api-key', function($request) { |
|
41 | 41 | $api_key = request()->headers->get('x-api-key'); |
42 | 42 | $class = config('auth.providers.ministries.model'); |
43 | 43 | |
44 | - return $class::whereHas('apiKey', function ($apiKey) use ($api_key) { |
|
44 | + return $class::whereHas('apiKey', function($apiKey) use ($api_key) { |
|
45 | 45 | return $apiKey->where('api_key', $api_key); |
46 | 46 | })->first(); |
47 | 47 | }); |
@@ -33,7 +33,7 @@ |
||
33 | 33 | */ |
34 | 34 | public function getUnsetFields() |
35 | 35 | { |
36 | - return ['image_id']; |
|
36 | + return [ 'image_id' ]; |
|
37 | 37 | } |
38 | 38 | |
39 | 39 | /** |