Skip to content

Commit

Permalink
dev
Browse files Browse the repository at this point in the history
  • Loading branch information
scrs_zdenek committed Aug 27, 2024
1 parent f154b05 commit 6d1fb85
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 8 deletions.
15 changes: 12 additions & 3 deletions app/Core/Settings/SettingsRepository.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,23 @@

namespace App\Core\Settings;

use Dibi\Connection;
use Drago\Attr\AttributeDetectionException;
use Drago\Attr\From;
use Drago\Attr\Table;
use Drago\Database\Database;


#[From(SettingsEntity::Table)]
class SettingsRepository extends Database
#[Table(SettingsEntity::Table)]
class SettingsRepository
{
use Database;

public function __construct(
protected Connection $connection,
) {
}


/**
* @throws AttributeDetectionException
*/
Expand Down
11 changes: 6 additions & 5 deletions app/Core/User/UserRepository.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
use Dibi\Connection;
use Dibi\Exception;
use Drago\Attr\AttributeDetectionException;
use Drago\Attr\From;
use Drago\Attr\Table;
use Drago\Authorization\Conf;
use Drago\Authorization\Control\Access\AccessRolesViewEntity;
use Drago\Authorization\Tracy\PanelCookie;
Expand All @@ -20,15 +20,16 @@
use Nette\Security\SimpleIdentity;


#[From(UsersEntity::Table, UsersEntity::PrimaryKey, class: UsersEntity::class)]
class UserRepository extends Database implements Authenticator, IdentityHandler
#[Table(UsersEntity::Table, UsersEntity::PrimaryKey, class: UsersEntity::class)]
class UserRepository implements Authenticator, IdentityHandler
{
use Database;

public function __construct(
protected Connection $db,
protected Connection $connection,
private readonly Passwords $password,
private readonly PanelCookie $panelCookie,
) {
parent::__construct($db);
}


Expand Down

0 comments on commit 6d1fb85

Please sign in to comment.