mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
Don't index into it again
If the string has a value, then we can just use that since it will be equal to that of the vector.
This commit is contained in:
parent
822d9f2b19
commit
71652f02c7
@ -952,7 +952,7 @@ int CConsole::TextEditCallback(ImGuiInputTextCallbackData* iData)
|
||||
string svHistory = (m_nHistoryPos >= 0) ? m_vHistory[m_nHistoryPos] : "";
|
||||
if (!svHistory.empty())
|
||||
{
|
||||
if (m_vHistory[m_nHistoryPos].find(' ') == string::npos)
|
||||
if (svHistory.find(' ') == string::npos)
|
||||
{
|
||||
// Append whitespace to previous entered command if absent or no parameters where passed.
|
||||
svHistory.append(" ");
|
||||
|
Loading…
x
Reference in New Issue
Block a user