File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -110,8 +110,8 @@ pub fn report_error(code: PgSqlErrorCode, msg: &str) {
110
110
111
111
#[ derive( Error , Debug ) ]
112
112
pub enum CreateRuntimeError {
113
- #[ error( "failed to create async runtime" ) ]
114
- FailedToCreateAsyncRuntime ,
113
+ #[ error( "failed to create async runtime: {0} " ) ]
114
+ FailedToCreateAsyncRuntime ( # [ from ] std :: io :: Error ) ,
115
115
}
116
116
117
117
impl From < CreateRuntimeError > for ErrorReport {
@@ -148,10 +148,7 @@ impl From<CreateRuntimeError> for ErrorReport {
148
148
/// ```
149
149
#[ inline]
150
150
pub fn create_async_runtime ( ) -> Result < Runtime , CreateRuntimeError > {
151
- Builder :: new_current_thread ( )
152
- . enable_all ( )
153
- . build ( )
154
- . map_err ( |_| CreateRuntimeError :: FailedToCreateAsyncRuntime )
151
+ Ok ( Builder :: new_current_thread ( ) . enable_all ( ) . build ( ) ?)
155
152
}
156
153
157
154
/// Get required option value from the `options` map
You can’t perform that action at this time.
0 commit comments