Closed dazza-codes closed 7 years ago
A change may need to be made to the SupportedFixityAlg
, i.e.
sdr = Node.find_by_namespace('sdr')
# => #<Node id: 2, namespace: "sdr", ... >
md5 = FixityAlg.find_by_name("md5")
# => #<FixityAlg id: 4, name: "md5", ... >
alg = SupportedFixityAlg.new
# => #<SupportedFixityAlg id: nil, node_id: nil, fixity_alg_id: nil>
alg.node = sdr
alg.fixity_alg = md5
alg.save
# => true
That has fixed the API response, i.e.
# Stanford
{"name":"Stanford Digital Repository",
"namespace":"sdr",
... snipped ...
"fixity_algorithms":["md5","sha256"],
"storage":{"region":"default","type":"default"}
}