Skip to main content

get_db_pool

Function get_db_pool 

Source
pub fn get_db_pool() -> &'static Pool<MySql>
Expand description

Retrieves a reference to the global database pool.

§Panics

Panics if init_db_pool has not been called, as the pool will not be initialized.

§Returns

A reference to the initialized Pool<MySql>.