improve map page

This commit is contained in:
lza_menace 2024-05-23 13:31:37 -07:00
parent 5bc00debc3
commit a44da731e9
3 changed files with 116 additions and 105 deletions

View file

@ -7,7 +7,7 @@ from urllib.parse import urlparse
from xmrnodes.helpers import rw_cache, get_highest_block
from xmrnodes.forms import SubmitNode
from xmrnodes.models import Node
from xmrnodes.models import Node, Peer
from xmrnodes import config
bp = Blueprint("meta", "meta")
@ -64,7 +64,7 @@ def index():
@bp.route("/map")
def map():
try:
peers = rw_cache("map_peers")
peers = Peer.select()
nodes = Node.select().where(Node.datetime_checked)
except:
flash("Couldn't load the map. Try again later.")