@k256/sdk 0.3.1 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1007,6 +1007,11 @@ function readU16(view, o) {
1007
1007
  o.v += 2;
1008
1008
  return val;
1009
1009
  }
1010
+ function readF64(view, o) {
1011
+ const val = view.getFloat64(o.v, true);
1012
+ o.v += 8;
1013
+ return val;
1014
+ }
1010
1015
  function readU8(view, o) {
1011
1016
  const val = view.getUint8(o.v);
1012
1017
  o.v += 1;
@@ -1065,12 +1070,16 @@ function readGossipPeer(view, data, o) {
1065
1070
  lastVote: readU64(view, o),
1066
1071
  rootSlot: readU64(view, o),
1067
1072
  wallclock: readU64(view, o),
1068
- // Geo/ASN enrichment from IPinfo Lite MMDB (server-side)
1073
+ // Geo/ASN enrichment from MaxMind GeoLite2 (server-side)
1069
1074
  countryCode: readVecU8AsString(view, data, o),
1070
1075
  continentCode: readVecU8AsString(view, data, o),
1071
1076
  asn: readVecU8AsString(view, data, o),
1072
1077
  asName: readVecU8AsString(view, data, o),
1073
- asDomain: readVecU8AsString(view, data, o)
1078
+ city: readVecU8AsString(view, data, o),
1079
+ region: readVecU8AsString(view, data, o),
1080
+ latitude: readF64(view, o),
1081
+ longitude: readF64(view, o),
1082
+ timezone: readVecU8AsString(view, data, o)
1074
1083
  };
1075
1084
  }
1076
1085
  function readGossipPeerVec(view, data, o) {