mirror of
https://github.com/aristocratos/btop.git
synced 2024-06-23 08:30:51 +12:00
More 'No need for const & in bool'
This commit is contained in:
parent
2f1bf0df01
commit
98b35d20a5
|
@ -65,7 +65,7 @@ namespace Config {
|
|||
bool _locked(const string& name);
|
||||
|
||||
//* Return bool for config key <name>
|
||||
inline const bool& getB(const string& name) { return bools.at(name); }
|
||||
inline bool getB(const string& name) { return bools.at(name); }
|
||||
|
||||
//* Return integer for config key <name>
|
||||
inline const int& getI(const string& name) { return ints.at(name); }
|
||||
|
@ -81,7 +81,7 @@ namespace Config {
|
|||
bool stringValid(const string& name, const string& value);
|
||||
|
||||
//* Set config key <name> to bool <value>
|
||||
inline void set(const string& name, const bool& value) {
|
||||
inline void set(const string& name, bool value) {
|
||||
if (_locked(name)) boolsTmp.insert_or_assign(name, value);
|
||||
else bools.at(name) = value;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue