The docblock for commerce_order_statuses() says:

 * Returns an array of some or all of the order statuses keyed by name.
 * Order statuses can only be defined by modules but may have settings
 * overridden that are stored in the database (weight and status). When this
 * function is first called, it will load all the statuses as defined by
 * hook_commerce_order_status_info() and update them based on the data in the
 * database. The final array will be cached for subsequent calls.

I can't see anywhere in this function where the database is hit. The only function calls are to invoke the hook and then drupal_alter().


rszrama’s picture

Title: incorrect mention of database in docs for commerce_order_statuses() » Remove the outdated message in the commerce_order_statuses() doc block
Component: Documentation » Order
Category: bug » task

Ahh, yeah, that was changed a while back. Took it out and credited you. : )

rszrama’s picture

Status: Active » Closed (fixed)