Fix ubuntu20+ compile "error" (#1)

* BehaviourDatabase::searchDigitNoLimit: catching exception with const ref

* - ident with tab
This commit is contained in:
Danilo Pucci 2023-01-21 16:18:46 -03:00 committed by GitHub
parent 918dae6771
commit ebdcffea33
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1440,10 +1440,10 @@ int32_t BehaviourDatabase::searchDigitNoLimit(const std::string& message)
try {
value = std::stoi(message.substr(start, end).c_str());
}
catch (std::invalid_argument) {
catch (std::invalid_argument const&) {
return 0;
}
catch (std::out_of_range) {
catch (std::out_of_range const&) {
return 0;
}