+3
-3
did/multi.go
+3
-3
did/multi.go
···
45
46
func (mr *MultiResolver) GetDocument(ctx context.Context, didstr string) (*did.Document, error) {
47
s := time.Now()
48
-
defer func() {
49
-
mrResolveDuration.WithLabelValues(didstr).Observe(time.Since(s).Seconds())
50
-
}()
51
52
pdid, err := did.ParseDID(didstr)
53
if err != nil {
···
55
}
56
57
method := pdid.Protocol()
58
59
res, ok := mr.handlers[method]
60
if !ok {
···
45
46
func (mr *MultiResolver) GetDocument(ctx context.Context, didstr string) (*did.Document, error) {
47
s := time.Now()
48
49
pdid, err := did.ParseDID(didstr)
50
if err != nil {
···
52
}
53
54
method := pdid.Protocol()
55
+
defer func() {
56
+
mrResolveDuration.WithLabelValues(method).Observe(time.Since(s).Seconds())
57
+
}()
58
59
res, ok := mr.handlers[method]
60
if !ok {