Add pruning support (#12)
This commit is contained in:
@@ -98,4 +98,14 @@ class Data {
|
||||
if (is_null($dbConn)) $db->close();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the last SQLite error message as a result array
|
||||
*
|
||||
* @param SQLite3 $db The database connection on which the error has occurred
|
||||
* @return string[] ['error' => message] for last SQLite error message
|
||||
*/
|
||||
public static function error(SQLite3 $db): array {
|
||||
return ['error' => 'SQLite error: ' . $db->lastErrorMsg()];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user