Stop using the unholy trinity in DatabaseError

RequestContext::getMain() shifts the blame, but at least
it's one less place in core.

Change-Id: I36ffad0ff2703c3326690eef2c07ef66aa532210
Merge "Stop using the unholy trinity in DatabaseError"