frostfs-node/pkg/morph
Evgenii Stratonikov d933609084
[#1689] client/netmap: Refactor Client.config()
There are problems with that code:
- explicit casts,
- `ErrConfigNotFound` which is not a part of a public API,
- hand-rolled assertions, even though neo-go already has everything we
  need.

So, remove the error, use `stackitem/Item.Try*()` methods for
conversions. Note, that readUint64Config() returns an error if the
parameter is missing. This is likely an error, but this behaviour is
preserved in this PR: `TryInteger()` returns error when applied to
`Null`. By contract, `TryBool()` returns false for `Null`, so this
PR introduces no functional changes.

Refs 82c7a50b8a/pkg/vm/stackitem/item.go (L418)

Change-Id: I445d28a7c6b5abb9a2bb97b57c0cc42d617e16f7
Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
2025-04-05 09:16:32 +03:00
..
client [#1689] client/netmap: Refactor Client.config() 2025-04-05 09:16:32 +03:00
event [#1598] golangci: Enable unparam linter 2025-01-14 09:06:47 +03:00
metrics [#424] morph: Fix cache metrics 2023-06-14 18:26:19 +03:00
subscriber [#1437] blobovnicza: Fix contextcheck linter 2024-11-13 10:36:08 +03:00
timer [#1507] timer/test: Use const for constants 2024-11-20 08:36:25 +00:00