zeitgeist icon indicating copy to clipboard operation
zeitgeist copied to clipboard

`Market` object is unable to figure out what it's assets are

Open maltekliemann opened this issue 1 year ago • 0 comments

I would like to add a function which returns the assets belonging to a particular market. IMO This should be a member function of Market. Problem is that the Market doesn't know it's ID.

The obvious solution is to add a market_id field. What bothers me is the mixing of responsiblities. Should a Market be aware of its ID? I don't think so. I guess the alternative is to add a query to market-commons? Or add a MarketWithId which combines MarketId and Market into a struct which can then execute the query.

maltekliemann avatar Aug 29 '23 20:08 maltekliemann