aeternity / ae_mdw

Aeternity Middleware in Elixir
26 stars 11 forks source link

fix: account active name counter #2027

Closed vatanasov closed 2 days ago

vatanasov commented 3 days ago

resolves: https://github.com/aeternity/ae_mdw/issues/1629

Currently the number of active names in the /names?owned_by=<x> and /names/count?owned_by=<x> are different, for example here: https://mainnet.aeternity.io/mdw/v3/names?owned_by=ak_ynYCVP5HXxEHmptuapK51d7wTRPFnrAnQSewqef5urYcMSJ6s and here https://mainnet.aeternity.io/mdw/v3/names/count?owned_by=ak_ynYCVP5HXxEHmptuapK51d7wTRPFnrAnQSewqef5urYcMSJ6s. My suspicion is that is is due to the counter not increased when a name is put to an auction and the auction ends. This will happen after this PR, as the Name.put_active function is called at that event.