mirror of
https://github.com/mudler/edgevpn.git
synced 2025-10-21 15:49:29 +08:00
🎨 Rework UI to show queued blocks
This commit is contained in:
@@ -84,9 +84,9 @@ func API(l string, ledger *blockchain.Ledger) error {
|
||||
|
||||
ec.GET("/*", echo.WrapHandler(http.StripPrefix("/", assetHandler)))
|
||||
|
||||
// ec.GET("/api/blockchain", func(c echo.Context) error {
|
||||
// return c.JSON(http.StatusOK, ledger.BlockChain())
|
||||
// })
|
||||
ec.GET("/api/blockchain", func(c echo.Context) error {
|
||||
return c.JSON(http.StatusOK, ledger.LastBlock())
|
||||
})
|
||||
|
||||
ec.GET("/api/ledger", func(c echo.Context) error {
|
||||
return c.JSON(http.StatusOK, ledger.CurrentData())
|
||||
|
Reference in New Issue
Block a user