MCPcopy Create free account
hub / github.com/QuipNetwork/cpp-sdk / ensure0x

Function ensure0x

src/quip_factory.cpp:16–20  ·  view source on GitHub ↗

Helper function to ensure a string has a single '0x' prefix

Source from the content-addressed store, hash-verified

14
15// Helper function to ensure a string has a single '0x' prefix
16static std::string ensure0x(const std::string &hex) {
17 if (hex.rfind("0x", 0) == 0)
18 return hex;
19 return "0x" + hex;
20}
21
22class QuipFactory::Impl {
23public:

Callers 1

depositToWinternitzMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected