Skip to content

Commit cdfced9

Browse files
author
Jorge Olivero
committed
main: Replace assert! with if statement
1 parent cb33cd7 commit cdfced9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

node/src/main.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,9 @@ fn async_main() -> impl Future<Item = (), Error = ()> + Send + 'static {
349349
.expect("invalid --store-connection-pool-size/STORE_CONNECTION_POOL_SIZE value");
350350

351351
// Minimum of two connections needed for the pool in order for the Store to bootstrap
352-
assert!(store_conn_pool_size > 1);
352+
if store_conn_pool_size <= 1 {
353+
panic!("--store-connection-pool-size/STORE_CONNECTION_POOL_SIZE must be > 1")
354+
}
353355

354356
// Set up Sentry, with release tracking and panic handling;
355357
// fall back to an empty URL, which will result in no errors being reported

0 commit comments

Comments
 (0)