diff --git a/plugins/portals-list.user.js b/plugins/portals-list.user.js index 899a1247..4b4bfbd5 100644 --- a/plugins/portals-list.user.js +++ b/plugins/portals-list.user.js @@ -13,7 +13,7 @@ // ==/UserScript== /* whatsnew -* 0.0.11: Add nominal energy column, fix sort bug when opened even amounts of times, nits +* 0.0.11: Add nominal energy column and # links, fix sort bug when opened even amounts of times, nits * 0.0.10: Fixed persistent css problem with alert * 0.0.9 : bugs hunt * 0.0.8 : Aborted to avoid problems with Niantic (export portals informations as csv or kml file) @@ -100,7 +100,7 @@ window.plugin.portalslist.getPortals = function() { }); var APgain= getAttackApGain(d).enemyAp; - var thisPortal = {'portal':d,'name':name,'team':team,'level':level,'guid':guid, 'resonators':resonators,'energyratio' : Math.floor(energy/maxenergy*100), 'shields':shields, 'APgain':APgain, 'EAP' : (energy/APgain).toFixed(2), 'energy': energy, 'maxenergy':maxenergy, 'lat':portal._latlng.lat, 'lng':portal._latlng.lng, 'address': address, 'img' : img}; + var thisPortal = {'portal': d, 'name': name, 'team': team, 'level': level, 'guid': guid, 'resonators': resonators, 'energyratio': maxenergy ? Math.floor(energy/maxenergy*100) : 0, 'shields': shields, 'APgain': APgain, 'EAP': (energy/APgain).toFixed(2), 'energy': energy, 'maxenergy': maxenergy, 'links': d.portalV2.linkedEdges.length, 'lat': portal._latlng.lat, 'lng': portal._latlng.lng, 'address': address, 'img': img}; window.plugin.portalslist.listPortals.push(thisPortal); }); @@ -219,6 +219,7 @@ window.plugin.portalslist.portalTable = function(sortBy, sortOrder, filter) { + '