95bee1895a
After running into a few nil pointer errors during development, it is clear that having this function return nil when a hash is not available is the wrong approach. Nearly every time, this lack of availability was due to a missing import statement for the hash. This is always a programming error. To avoid future confusion, we now appropriately panic when the hash function is not imported by the application. More dynamic uses of the package should call Algorithm.Available() before calling Algorithm.Hash() to avoid this panic. Signed-off-by: Stephen J Day <stephen.day@docker.com> |
||
---|---|---|
.. | ||
digest.go | ||
digest_test.go | ||
digester.go | ||
digester_resumable_test.go | ||
doc.go | ||
set.go | ||
set_test.go | ||
verifiers.go | ||
verifiers_test.go |