mirror of
https://github.com/actix/examples
synced 2024-11-27 16:02:57 +01:00
Fix error message for failed connection (#144)
This commit is contained in:
parent
733eb93a97
commit
b0d3c652b2
@ -14,7 +14,7 @@ pub fn init_pool(database_url: &str) -> Result<PgPool, PoolError> {
|
||||
}
|
||||
|
||||
fn get_conn(pool: &PgPool) -> Result<PgPooledConnection, &'static str> {
|
||||
pool.get().map_err(|_| "can get connection")
|
||||
pool.get().map_err(|_| "Can't get connection")
|
||||
}
|
||||
|
||||
pub fn get_all_tasks(pool: &PgPool) -> Result<Vec<Task>, &'static str> {
|
||||
|
Loading…
Reference in New Issue
Block a user