Skip to content

Commit 7897514

Browse files
authored
Merge pull request #148 from BinaryStudioAcademy/dev
Release v1.2.0
2 parents 7fdf335 + b3c4cb4 commit 7897514

File tree

160 files changed

+8352
-5672
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

160 files changed

+8352
-5672
lines changed

.styleci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
preset: psr2
1+
preset: psr12
22

33
risky: false
44

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ services:
66
language: php
77

88
php:
9-
- 7.3
9+
- 8.0
1010

1111
cache:
1212
directories:

backend/.env.example

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ APP_DEBUG=true
55
APP_URL=http://localhost
66

77
LOG_CHANNEL=stack
8+
LOG_DEPRECATIONS_CHANNEL=null
9+
LOG_LEVEL=debug
810

911
DB_CONNECTION=mysql
1012
DB_HOST=127.0.0.1
@@ -15,15 +17,18 @@ DB_PASSWORD=secret
1517

1618
BROADCAST_DRIVER=log
1719
CACHE_DRIVER=file
20+
FILESYSTEM_DRIVER=public
1821
QUEUE_CONNECTION=sync
1922
SESSION_DRIVER=file
2023
SESSION_LIFETIME=120
2124

25+
MEMCACHED_HOST=127.0.0.1
26+
2227
REDIS_HOST=127.0.0.1
2328
REDIS_PASSWORD=null
2429
REDIS_PORT=6379
2530

26-
MAIL_DRIVER=smtp
31+
MAIL_MAILER=smtp
2732
MAIL_HOST=smtp.mailtrap.io
2833
MAIL_PORT=2525
2934
MAIL_USERNAME=null
@@ -36,6 +41,7 @@ AWS_ACCESS_KEY_ID=
3641
AWS_SECRET_ACCESS_KEY=
3742
AWS_DEFAULT_REGION=us-east-1
3843
AWS_BUCKET=
44+
AWS_USE_PATH_STYLE_ENDPOINT=false
3945

4046
PUSHER_APP_ID=
4147
PUSHER_APP_KEY=
@@ -52,4 +58,3 @@ APP_PORT=7777
5258
MYSQL_PORT_TEST_DB=33062
5359

5460
BEANSTALKD_HOST=
55-
FILESYSTEM_DRIVER=public

backend/.gitignore

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,13 @@
55
/vendor
66
.env
77
.phpunit.result.cache
8+
docker-compose.override.yml
89
Homestead.json
910
Homestead.yaml
1011
npm-debug.log
1112
yarn-error.log
12-
.idea
13-
.vscode
13+
/.idea
14+
/.vscode
1415
.mysqldata
1516
_ide_helper.php
1617
.phpstorm.meta.php

backend/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
## Technologies
44

5-
* PHP 7.3
6-
* [Laravel 6](https://laravel.com)
5+
* PHP 8.0
6+
* [Laravel 8](https://laravel.com)
77
* [Docker](https://www.docker.com/)
88
* [Docker-compose](https://docs.docker.com/compose/)
99
* [Beanstalkd](https://github.com/beanstalkd/beanstalkd) - message queue (очередь сообщений для обработки тяжелых задач асинхронно)
Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,16 @@
11
<?php
22

3-
declare(strict_types = 1);
3+
declare(strict_types=1);
44

55
namespace App\Action\Auth;
66

77
final class AuthenticationResponse
88
{
9-
private $accessToken;
10-
private $tokenType;
11-
private $expiresIn;
12-
139
public function __construct(
14-
string $accessToken,
15-
string $tokenType,
16-
int $expiresIn
10+
private string $accessToken,
11+
private string $tokenType,
12+
private int $expiresIn
1713
) {
18-
$this->accessToken = $accessToken;
19-
$this->tokenType = $tokenType;
20-
$this->expiresIn = $expiresIn;
2114
}
2215

2316
public function getAccessToken(): string
@@ -34,4 +27,4 @@ public function getExpiresIn(): int
3427
{
3528
return $this->expiresIn;
3629
}
37-
}
30+
}

backend/app/Action/Auth/GetAuthenticatedUserAction.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
declare(strict_types = 1);
3+
declare(strict_types=1);
44

55
namespace App\Action\Auth;
66

@@ -12,4 +12,4 @@ public function execute(): GetAuthenticatedUserResponse
1212
{
1313
return new GetAuthenticatedUserResponse(Auth::user());
1414
}
15-
}
15+
}
Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,19 @@
11
<?php
22

3-
declare(strict_types = 1);
3+
declare(strict_types=1);
44

55
namespace App\Action\Auth;
66

7-
use App\Entity\User;
7+
use App\Models\User;
88

99
final class GetAuthenticatedUserResponse
1010
{
11-
private $user;
12-
13-
public function __construct(User $user)
11+
public function __construct(private User $user)
1412
{
15-
$this->user = $user;
1613
}
1714

1815
public function getUser(): User
1916
{
2017
return $this->user;
2118
}
22-
}
19+
}

backend/app/Action/Auth/LoginAction.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
declare(strict_types = 1);
3+
declare(strict_types=1);
44

55
namespace App\Action\Auth;
66

@@ -26,4 +26,4 @@ public function execute(LoginRequest $request): AuthenticationResponse
2626
auth()->factory()->getTTL() * 60
2727
);
2828
}
29-
}
29+
}
Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,15 @@
11
<?php
22

3-
declare(strict_types = 1);
3+
declare(strict_types=1);
44

55
namespace App\Action\Auth;
66

77
final class LoginRequest
88
{
9-
private $email;
10-
private $password;
11-
129
public function __construct(
13-
string $email,
14-
string $password
10+
private string $email,
11+
private string $password
1512
) {
16-
$this->email = $email;
17-
$this->password = $password;
1813
}
1914

2015
public function getEmail(): string
@@ -26,4 +21,4 @@ public function getPassword(): string
2621
{
2722
return $this->password;
2823
}
29-
}
24+
}

0 commit comments

Comments
 (0)