mirror of
https://gitlab.com/niansa/discord_llama.git
synced 2025-03-06 20:48:25 +01:00
Remove all leading spaces
This commit is contained in:
parent
ee9eaa29d1
commit
96baf6d0f0
1 changed files with 2 additions and 2 deletions
4
main.cpp
4
main.cpp
|
@ -452,8 +452,8 @@ int main(int argc, char **argv) {
|
|||
// Read value
|
||||
std::string value;
|
||||
std::getline(cfgf, value);
|
||||
// Erase whitespace
|
||||
value.erase(0, 1);
|
||||
// Erase all leading spaces
|
||||
while (!value.empty() && (value[0] == ' ' || value[0] == '\t')) value.erase(0, 1);
|
||||
// Check key and ignore comment lines
|
||||
if (key == "token") {
|
||||
cfg.token = std::move(value);
|
||||
|
|
Loading…
Add table
Reference in a new issue