HomeDevCentral

Generalize error() to all engines

Description

Generalize error() to all engines

Summary:
Even if we throw exceptions, error handling of legacy code
is still calling $db->error() in MySQL context to read
errno/error messages.

While those fields are populated in the exception as context,
it makes sense to expose this method at base abstraction level,
so code migrating to use keruald/database can keep its current
error handling.

Blackhole pure and mock implementations returns an empty array.

Test Plan: Use in Obsidian workspaces/src/includes/error.php

Differential Revision: https://devcentral.nasqueron.org/D3784

Details

Provenance
derecksonAuthored on Mon, Oct 20, 17:09
derecksonPushed on Mon, Oct 20, 17:15
Differential Revision
D3784: Generalize error() to all engines
Parents
rKERUALD5e492da098f5: Import database unit tests from Obsidian Workspaces
Branches
Unknown
Tags
Unknown
References
tag: database/0.5.2