Skip to content

Commit 01aadeb

Browse files
authored
Merge pull request #3 from jr-cologne/jr-cologne_type-hint-everywhere
fixes #2
2 parents 316a0aa + ef72250 commit 01aadeb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

DB.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ public function connected() {
7979
}
8080

8181
// select/get data from database
82-
public function select(string $sql, $where=null, $fetch_mode=PDO::FETCH_ASSOC) {
82+
public function select(string $sql, array $where=null, int $fetch_mode=PDO::FETCH_ASSOC) {
8383
$error_types = self::$error_types;
8484
$pdo = $this->pdo;
8585

@@ -128,7 +128,7 @@ public function insert(string $sql, array $values) {
128128
}
129129

130130
// delete data/rows from database
131-
public function delete(string $sql, $where=null) {
131+
public function delete(string $sql, array $where=null) {
132132
$error_types = self::$error_types;
133133
$pdo = $this->pdo;
134134

@@ -153,7 +153,7 @@ public function delete(string $sql, $where=null) {
153153
}
154154

155155
// update data/rows in database
156-
public function update(string $sql, $values) {
156+
public function update(string $sql, array $values) {
157157
$error_types = self::$error_types;
158158
$pdo = $this->pdo;
159159

@@ -173,4 +173,4 @@ public function update(string $sql, $values) {
173173
}
174174
}
175175
}
176-
?>
176+
?>

0 commit comments

Comments
 (0)