3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-01 09:19:23 +01:00

inspircd: burst shorter version strings on insp3

These get shown in /map, for example.
This commit is contained in:
James Lu 2019-05-31 18:12:26 -07:00
parent b260a28c8f
commit 917543dd12

View File

@ -446,10 +446,13 @@ class InspIRCdProtocol(TS6BaseProtocol):
sdesc=self.serverdata.get('serverdesc') or conf.conf['pylink']['serverdesc']))
self._send_with_prefix(self.sid, 'BURST %s' % ts)
# InspIRCd sends VERSION data on link, instead of whenever requested by a client.
# InspIRCd sends VERSION data on link, instead of when requested by a client.
if self.proto_ver >= 1205:
for version_type in {'version', 'fullversion', 'rawversion'}:
self._send_with_prefix(self.sid, 'SINFO %s :%s' % (version_type, self.version()))
verstr = self.version()
for version_type in {'version', 'rawversion'}:
self._send_with_prefix(self.sid, 'SINFO %s :%s' % (version_type, verstr.split(' ', 1)[0]))
self._send_with_prefix(self.sid, 'SINFO fullversion :%s' % verstr)
else:
self._send_with_prefix(self.sid, 'VERSION :%s' % self.version())
self._send_with_prefix(self.sid, 'ENDBURST')