public static bool TypeEquals(TLRPCError error, ErrorType type) { if (error == null) { return(false); } return(error.TypeEquals(type)); }
public static bool CodeEquals(TLRPCError error, ErrorCode code) { if (error.Code != null && Enum.IsDefined(typeof(ErrorCode), error.Code.Value)) { return((ErrorCode)error.Code.Value == code); } return(false); }