@@ 63-69 (lines=7) @@ | ||
60 | /** |
|
61 | * {@inheritdoc} |
|
62 | */ |
|
63 | public function userOfId(UserId $anId) |
|
64 | { |
|
65 | $statement = $this->execute('SELECT * FROM user WHERE id = :id', ['id' => $anId->id()]); |
|
66 | if ($row = $statement->fetch(\PDO::FETCH_ASSOC)) { |
|
67 | return $this->buildUser($row); |
|
68 | } |
|
69 | } |
|
70 | ||
71 | /** |
|
72 | * {@inheritdoc} |
|
@@ 74-80 (lines=7) @@ | ||
71 | /** |
|
72 | * {@inheritdoc} |
|
73 | */ |
|
74 | public function all() |
|
75 | { |
|
76 | $statement = $this->execute('SELECT * FROM user', []); |
|
77 | if ($row = $statement->fetch(\PDO::FETCH_ASSOC)) { |
|
78 | return $this->buildUser($row); |
|
79 | } |
|
80 | } |
|
81 | ||
82 | /** |
|
83 | * {@inheritdoc} |