Skip to content

Commit 96ee3a8

Browse files
committed
refactor: clean up codes
1 parent 85ff264 commit 96ee3a8

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

src/endstone/runtime/bedrock_hooks/rak_peer_helper.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,8 @@ RakNet::StartupResult RakPeerHelper::peerStartup(RakNet::RakPeerInterface *peer,
2424
{
2525
auto new_def = def;
2626
new_def.max_num_connections = SharedConstants::NetworkDefaultMaxConnections;
27-
28-
auto result = ENDSTONE_HOOK_CALL_ORIGINAL(&RakPeerHelper::peerStartup, this, peer, new_def, purpose);
2927
if (peer && purpose == PeerPurpose::Gameplay) {
3028
peer->SetLimitIPConnectionFrequency(true); // limit connections from the same ip in 100 milliseconds.
3129
}
32-
return result;
30+
return ENDSTONE_HOOK_CALL_ORIGINAL(&RakPeerHelper::peerStartup, this, peer, new_def, purpose);
3331
}

0 commit comments

Comments
 (0)