@@ -47,10 +47,10 @@ impl SpinRuntimeConfig {
47
47
) -> anyhow:: Result < Option < super :: RuntimeConfig > > {
48
48
let maybe_blocked_networks = self
49
49
. blocked_networks_from_table ( table)
50
- . context ( "parsing blocked_networks " ) ?;
50
+ . context ( "failed to parse [outbound_networking] table " ) ?;
51
51
let maybe_tls_configs = self
52
52
. tls_configs_from_table ( table)
53
- . context ( "parsing client_tls" ) ?;
53
+ . context ( "failed to parse [[ client_tls]] table " ) ?;
54
54
55
55
if maybe_blocked_networks. is_none ( ) && maybe_tls_configs. is_none ( ) {
56
56
return Ok ( None ) ;
@@ -106,7 +106,7 @@ impl SpinRuntimeConfig {
106
106
. into_iter ( )
107
107
. map ( |toml_config| self . load_tls_config ( toml_config) )
108
108
. collect :: < anyhow:: Result < Vec < _ > > > ( )
109
- . context ( "failed to parse TLS configs from TOML " ) ?;
109
+ . context ( "failed to parse TLS config " ) ?;
110
110
Ok ( Some ( tls_configs) )
111
111
}
112
112
@@ -124,12 +124,9 @@ impl SpinRuntimeConfig {
124
124
} = toml_config;
125
125
ensure ! (
126
126
!component_ids. is_empty( ) ,
127
- "[[client_tls]] 'component_ids' list may not be empty"
128
- ) ;
129
- ensure ! (
130
- !hosts. is_empty( ) ,
131
- "[[client_tls]] 'hosts' list may not be empty"
127
+ "'component_ids' list may not be empty"
132
128
) ;
129
+ ensure ! ( !hosts. is_empty( ) , "'hosts' list may not be empty" ) ;
133
130
134
131
let components = component_ids. into_iter ( ) . map ( Into :: into) . collect ( ) ;
135
132
0 commit comments