File tree Expand file tree Collapse file tree 1 file changed +0
-31
lines changed
Expand file tree Collapse file tree 1 file changed +0
-31
lines changed Original file line number Diff line number Diff line change @@ -526,37 +526,6 @@ pub fn trace_labels() -> HashMap<String, String> {
526526 l
527527}
528528
529- #[ derive( Clone , Debug ) ]
530- enum DiscoveryError {
531- DiscoveryRejected ,
532- Inner ( String ) ,
533- }
534-
535- impl std:: fmt:: Display for DiscoveryError {
536- fn fmt ( & self , f : & mut std:: fmt:: Formatter < ' _ > ) -> std:: fmt:: Result {
537- match self {
538- DiscoveryError :: DiscoveryRejected => write ! ( f, "discovery rejected" ) ,
539- DiscoveryError :: Inner ( e) => e. fmt ( f) ,
540- }
541- }
542- }
543-
544- impl std:: error:: Error for DiscoveryError { }
545-
546- impl From < Error > for DiscoveryError {
547- fn from ( orig : Error ) -> Self {
548- if let Some ( inner) = orig. downcast_ref :: < DiscoveryError > ( ) {
549- return inner. clone ( ) ;
550- }
551-
552- if orig. is :: < DiscoveryRejected > ( ) || orig. is :: < profiles:: InvalidProfileAddr > ( ) {
553- return DiscoveryError :: DiscoveryRejected ;
554- }
555-
556- DiscoveryError :: Inner ( orig. to_string ( ) )
557- }
558- }
559-
560529fn is_discovery_rejected ( err : & Error ) -> bool {
561530 fn is_rejected ( err : & ( dyn std:: error:: Error + ' static ) ) -> bool {
562531 err. is :: < DiscoveryRejected > ( )
You can’t perform that action at this time.
0 commit comments