Skip to content

Commit 0d1d70c

Browse files
committed
add Db class so we can reuse it in tests
1 parent 5bcd2d2 commit 0d1d70c

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

lib/Db.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<?php
2+
namespace Pdsinterop\PhpSolid;
3+
4+
class Db {
5+
public static $pdo;
6+
public static function connect() {
7+
if (!isset(self::$pdo)) {
8+
self::$pdo = new \PDO("sqlite:" . DBPATH);
9+
}
10+
}
11+
}

0 commit comments

Comments
 (0)