MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / Remove

Method Remove

src/network/network.cpp:206–213  ·  view source on GitHub ↗

* Remove the given key from the authorized keys, when it is exists. * @param key The key to remove. * @return \c true when the key was removed, \c false when the key did not exist. */

Source from the content-addressed store, hash-verified

204 * @return \c true when the key was removed, \c false when the key did not exist.
205 */
206bool NetworkAuthorizedKeys::Remove(std::string_view key)
207{
208 auto iter = FindKey(this, key);
209 if (iter == this->end()) return false;
210
211 this->erase(iter);
212 return true;
213}
214
215
216uint8_t NetworkSpectatorCount()

Callers 1

NodeListClass · 0.45

Calls 3

FindKeyFunction · 0.85
endMethod · 0.45
eraseMethod · 0.45

Tested by

no test coverage detected