diff options
author | ClementTsang <cjhtsang@uwaterloo.ca> | 2020-09-01 00:29:46 -0400 |
---|---|---|
committer | ClementTsang <cjhtsang@uwaterloo.ca> | 2020-09-01 00:29:46 -0400 |
commit | d24a797ce9a137cbce68d621693dc7db60db2ba8 (patch) | |
tree | 24779d2241f65f16840918acf40a0e2701c94222 | |
parent | 01f65d378bfa7108a9e6ce65cef28fa735e798c1 (diff) |
other: Add config error if default_widget_count is not used with default_widget_type
-rw-r--r-- | src/options.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/options.rs b/src/options.rs index c2e33993..1d25ca85 100644 --- a/src/options.rs +++ b/src/options.rs @@ -613,7 +613,9 @@ fn get_default_widget_and_count( Ok((widget_type, widget_count as u64)) } } else { - Ok((None, 1)) + Err(BottomError::ConfigError( + "cannot set 'default_widget_count' by itself, it must be used with 'default_widget_type'.".to_string(), + )) } } |