Use references instead of copying the string.
This commit is contained in:
parent
c3f1b53535
commit
59a64625fa
@ -180,9 +180,9 @@ public:
|
||||
* \throw out_of_range if there is no data for 'type'.
|
||||
* \param type Type of kart (e.g. heavy, medium, ...).
|
||||
*/
|
||||
const KartProperties& getKartProperties(std::string type)
|
||||
const KartProperties& getKartProperties(const std::string &type)
|
||||
{
|
||||
return *m_kart_properties.at(type);
|
||||
return *m_kart_properties.at(type);
|
||||
} // getKartProperties
|
||||
}
|
||||
; // STKConfig
|
||||
|
Loading…
Reference in New Issue
Block a user