add HTTPSpecialCaseException for database connection
This commit is contained in:
parent
1f27156004
commit
ac0ee6441d
@ -17,7 +17,7 @@ final class Model
|
|||||||
try{
|
try{
|
||||||
self::$conn = new PDO($PDO_URI, $_ENV["DB_USERNAME"], $_ENV["DB_PASSWORD"]);
|
self::$conn = new PDO($PDO_URI, $_ENV["DB_USERNAME"], $_ENV["DB_PASSWORD"]);
|
||||||
}catch(PDOException $e){
|
}catch(PDOException $e){
|
||||||
die("Connection to the database failed");
|
throw new HTTPSpecialCaseException(500, "Connection to the database failed");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user