@@ -109,6 +109,14 @@ impl ClientBuilder {
109
109
/// If you have enabled the `framework`-feature (on by default), you must specify
110
110
/// a framework via the [`Self::framework`] method,
111
111
/// otherwise awaiting the builder will cause a panic.
112
+ #[ cfg( feature = "gateway" ) ]
113
+ #[ cfg_attr(
114
+ feature = "absolute_ratelimits" ,
115
+ deprecated = "\n \
116
+ You've enabled the absolute_ratelimits feature but it has been removed.\n \
117
+ Configure absolute ratelimits via Ratelimiter::set_absolute_ratelimits instead.\n \
118
+ You can set the Ratelimiter of Http via HttpBuilder::ratelimiter."
119
+ ) ]
112
120
pub fn new ( token : impl AsRef < str > , intents : GatewayIntents ) -> Self {
113
121
Self :: _new ( Http :: new ( token. as_ref ( ) ) , intents)
114
122
}
@@ -120,6 +128,13 @@ impl ClientBuilder {
120
128
/// If you have enabled the `framework`-feature (on by default), you must specify
121
129
/// a framework via the [`Self::framework`] method,
122
130
/// otherwise awaiting the builder will cause a panic.
131
+ #[ cfg_attr(
132
+ feature = "absolute_ratelimits" ,
133
+ deprecated = "\n \
134
+ You've enabled the absolute_ratelimits feature but it has been removed.\n \
135
+ Configure absolute ratelimits via Ratelimiter::set_absolute_ratelimits instead.\n \
136
+ You can set the Ratelimiter of Http via HttpBuilder::ratelimiter."
137
+ ) ]
123
138
pub fn new_with_http ( http : Http , intents : GatewayIntents ) -> Self {
124
139
Self :: _new ( http, intents)
125
140
}
@@ -345,7 +360,6 @@ impl ClientBuilder {
345
360
}
346
361
}
347
362
348
- #[ cfg( feature = "gateway" ) ]
349
363
impl IntoFuture for ClientBuilder {
350
364
type Output = Result < Client > ;
351
365
@@ -679,6 +693,13 @@ pub struct Client {
679
693
}
680
694
681
695
impl Client {
696
+ #[ cfg_attr(
697
+ feature = "absolute_ratelimits" ,
698
+ deprecated = "\n \
699
+ You've enabled the absolute_ratelimits feature but it has been removed.\n \
700
+ Configure absolute ratelimits via Ratelimiter::set_absolute_ratelimits instead.\n \
701
+ You can set the Ratelimiter of Http via HttpBuilder::ratelimiter."
702
+ ) ]
682
703
pub fn builder ( token : impl AsRef < str > , intents : GatewayIntents ) -> ClientBuilder {
683
704
ClientBuilder :: new ( token, intents)
684
705
}
0 commit comments