• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

ericfortmeyer / activity-log / 19770959394

28 Nov 2025 06:00PM UTC coverage: 52.31% (-1.3%) from 53.631%
19770959394

push

github

web-flow
Merge pull request #36 from ericfortmeyer/add-sqlite-storage

feat: use sqlite-storage library

4 of 23 new or added lines in 4 files covered. (17.39%)

385 of 736 relevant lines covered (52.31%)

2.13 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/Bootstrapper.php
1
<?php
2

3
declare(strict_types=1);
4

5
namespace EricFortmeyer\ActivityLog;
6

7
use EricFortmeyer\ActivityLog\Infrastructure\Auth\CallbackMiddleware;
8
use EricFortmeyer\ActivityLog\Infrastructure\Auth\LoginMiddleware;
9
use EricFortmeyer\ActivityLog\Infrastructure\Auth\LogoutMiddleware;
10
use Phpolar\Phpolar\App;
11
use Psr\Container\ContainerInterface;
12
use Psr\Http\Message\ServerRequestInterface;
13

14
use const EricFortmeyer\ActivityLog\config\DiTokens\CALLBACK_MIDDLEWARE;
15
use const EricFortmeyer\ActivityLog\config\DiTokens\LOGIN_MIDDLEWARE;
16
use const EricFortmeyer\ActivityLog\config\DiTokens\LOGOUT_MIDDLEWARE;
17

18
/**
19
 * Bootstraps the application
20
 */
21
final readonly class Bootstrapper
22
{
23
    public function __construct(
24
        private ContainerInterface $container,
NEW
25
    ) {}
×
26

27
    public function __invoke(): void
28
    {
NEW
29
        App::create($this->container)
×
NEW
30
            ->useCsrfMiddleware()
×
NEW
31
            ->useAuthorization()
×
NEW
32
            ->use($this->getCallbackMiddleWare())
×
NEW
33
            ->use($this->getLoginMiddleWare())
×
NEW
34
            ->use($this->getLogoutMiddleWare())
×
NEW
35
            ->receive($this->getRequest());
×
36
    }
37

38
    public function getRequest(): ServerRequestInterface
39
    {
40
        /**
41
         * @var ServerRequestInterface
42
         */
NEW
43
        $serverRequest = $this->container->get(ServerRequestInterface::class);
×
NEW
44
        return $serverRequest;
×
45
    }
46

47
    public function getLoginMiddleWare(): LoginMiddleware
48
    {
49
        /**
50
         * @var LoginMiddleware
51
         */
NEW
52
        $loginMiddleware = $this->container->get(LOGIN_MIDDLEWARE);
×
NEW
53
        return $loginMiddleware;
×
54
    }
55

56
    public function getLogoutMiddleWare(): LogoutMiddleware
57
    {
58
        /**
59
         * @var LogoutMiddleware
60
         */
NEW
61
        $logoutMiddleware = $this->container->get(LOGOUT_MIDDLEWARE);
×
NEW
62
        return $logoutMiddleware;
×
63
    }
64

65
    public function getCallbackMiddleWare(): CallbackMiddleware
66
    {
67
        /**
68
         * @var CallbackMiddleware
69
         */
NEW
70
        $callbackMiddleware = $this->container->get(CALLBACK_MIDDLEWARE);
×
NEW
71
        return $callbackMiddleware;
×
72
    }
73
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc