Skip to content

Commit

Permalink
Fix error with if(string)
Browse files Browse the repository at this point in the history
  • Loading branch information
henryiii committed Nov 28, 2017
1 parent 8be496e commit 7726dc2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion include/CLI/App.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -589,7 +589,7 @@ class App {
remove_option(config_ptr_);

// Only add config if option passed
if(name) {
if(!name.empty()) {
config_name_ = default_filename;
config_required_ = required;
config_ptr_ = add_option(name, config_name_, help, !default_filename.empty());
Expand Down
3 changes: 2 additions & 1 deletion tests/IniTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,8 @@ TEST_F(TApp, IniSubFailure) {

EXPECT_THROW(run(), CLI::INIError);
}
d TEST_F(TApp, IniNoSubFailure) {

TEST_F(TApp, IniNoSubFailure) {

TempFile tmpini{"TestIniTmp.ini"};

Expand Down

0 comments on commit 7726dc2

Please sign in to comment.