From: asonix Date: Mon, 20 Apr 2020 18:09:10 +0000 (-0500) Subject: Remove unused methods X-Git-Url: http://these/git/%7B%60%24%7BwebArchiveUrl%7D/%22%7B%7D/%24%7B%60data:application/static/%7B%60https:/%7BcommunityRSSUrl%28?a=commitdiff_plain;h=05b961a90a2b049f391fec7a78aa9fb4db6c3ed2;p=lemmy.git Remove unused methods --- diff --git a/server/src/rate_limit/rate_limiter.rs b/server/src/rate_limit/rate_limiter.rs index 8f598c3d..926e0989 100644 --- a/server/src/rate_limit/rate_limiter.rs +++ b/server/src/rate_limit/rate_limiter.rs @@ -48,36 +48,6 @@ impl RateLimiter { } } - pub fn check_rate_limit_register(&mut self, ip: &str, check_only: bool) -> Result<(), Error> { - self.check_rate_limit_full( - RateLimitType::Register, - ip, - Settings::get().rate_limit.register, - Settings::get().rate_limit.register_per_second, - check_only, - ) - } - - pub fn check_rate_limit_post(&mut self, ip: &str, check_only: bool) -> Result<(), Error> { - self.check_rate_limit_full( - RateLimitType::Post, - ip, - Settings::get().rate_limit.post, - Settings::get().rate_limit.post_per_second, - check_only, - ) - } - - pub fn check_rate_limit_message(&mut self, ip: &str, check_only: bool) -> Result<(), Error> { - self.check_rate_limit_full( - RateLimitType::Message, - ip, - Settings::get().rate_limit.message, - Settings::get().rate_limit.message_per_second, - check_only, - ) - } - #[allow(clippy::float_cmp)] pub(super) fn check_rate_limit_full( &mut self,