Page MenuHomeDevCentral

Generalize error() to all engines
ClosedPublic

Authored by dereckson on Mon, Oct 20, 17:14.
Tags
None
Referenced Files
F12582483: D3784.diff
Tue, Nov 11, 12:08
Unknown Object (File)
Sat, Nov 8, 13:16
Unknown Object (File)
Sat, Nov 8, 07:19
Unknown Object (File)
Fri, Nov 7, 18:31
Unknown Object (File)
Fri, Nov 7, 16:30
Unknown Object (File)
Fri, Nov 7, 09:30
Unknown Object (File)
Fri, Nov 7, 05:31
Unknown Object (File)
Wed, Nov 5, 07:50
Subscribers
None

Details

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

Diff Detail

Repository
rKERUALD Keruald libraries development repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable