diff --git a/explorer/adapter.cpp b/explorer/adapter.cpp index 092222f58d..2169676692 100644 --- a/explorer/adapter.cpp +++ b/explorer/adapter.cpp @@ -2237,6 +2237,11 @@ class Adapter : public Node::IObserver, public IAdapter { json get_assets_at(Height h) override { + Height currentHeight = _nodeBackend.m_Cursor.m_hh.m_Height; + + if (h != MaxHeight && h > currentHeight) + return get_block_not_found(h); + json jAssets = json::array(); jAssets.push_back(json::array({ MakeTableHdr("Aid"), @@ -2248,7 +2253,7 @@ class Adapter : public Node::IObserver, public IAdapter { })); - bool bCurrent = (h >= _nodeBackend.m_Cursor.m_hh.m_Height); + bool bCurrent = (h >= currentHeight); Asset::Full ai; for (ai.m_ID = 0; ; )