oceanprotocol/react

View on GitHub
src/hooks/useMetadata/useMetadata.ts

Summary

Maintainability
A
3 hrs
Test Coverage

Function useMetadata has 85 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function useMetadata(asset?: DID | string | DDO): UseMetadata {
  const { ocean, config, status, networkId } = useOcean()
  const [internalDdo, setDDO] = useState<DDO>()
  const [internalDid, setDID] = useState<DID | string>()
  const [metadata, setMetadata] = useState<Metadata>()
Severity: Major
Found in src/hooks/useMetadata/useMetadata.ts - About 3 hrs to fix

    There are no issues that match your filters.

    Category
    Status