From 73e5c8ba05a1b51721f24425e79d71b27525d29e Mon Sep 17 00:00:00 2001 From: nick evans Date: Tue, 22 Nov 2022 12:27:37 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=93=9A=20Fix=20deprecated=20constants=20r?= =?UTF-8?q?doc?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Also, revert to default section after flags are read --- lib/net/imap/flags.rb | 1 + lib/net/imap/sasl/cram_md5_authenticator.rb | 2 +- lib/net/imap/sasl/digest_md5_authenticator.rb | 2 +- lib/net/imap/sasl/login_authenticator.rb | 2 +- lib/net/imap/sasl/plain_authenticator.rb | 2 +- lib/net/imap/sasl/xoauth2_authenticator.rb | 2 +- 6 files changed, 6 insertions(+), 5 deletions(-) diff --git a/lib/net/imap/flags.rb b/lib/net/imap/flags.rb index 68bb8b81..88091d01 100644 --- a/lib/net/imap/flags.rb +++ b/lib/net/imap/flags.rb @@ -257,5 +257,6 @@ class IMAP < Protocol # special use is likely not to be supported. TRASH = :Trash + # :section: end end diff --git a/lib/net/imap/sasl/cram_md5_authenticator.rb b/lib/net/imap/sasl/cram_md5_authenticator.rb index d3238f5b..df40af91 100644 --- a/lib/net/imap/sasl/cram_md5_authenticator.rb +++ b/lib/net/imap/sasl/cram_md5_authenticator.rb @@ -60,7 +60,7 @@ def hmac_md5(text, key) end end - CramMD5Authenticator = SASL::CramMD5Authenticator + CramMD5Authenticator = SASL::CramMD5Authenticator # :nodoc: deprecate_constant :CramMD5Authenticator end diff --git a/lib/net/imap/sasl/digest_md5_authenticator.rb b/lib/net/imap/sasl/digest_md5_authenticator.rb index 59de42eb..253006c2 100644 --- a/lib/net/imap/sasl/digest_md5_authenticator.rb +++ b/lib/net/imap/sasl/digest_md5_authenticator.rb @@ -340,7 +340,7 @@ def qdval(k, v) end end - DigestMD5Authenticator = SASL::DigestMD5Authenticator + DigestMD5Authenticator = SASL::DigestMD5Authenticator # :nodoc: deprecate_constant :DigestMD5Authenticator end diff --git a/lib/net/imap/sasl/login_authenticator.rb b/lib/net/imap/sasl/login_authenticator.rb index 9ad6f2a4..c1d719bb 100644 --- a/lib/net/imap/sasl/login_authenticator.rb +++ b/lib/net/imap/sasl/login_authenticator.rb @@ -56,7 +56,7 @@ def initialize(user, password, warn_deprecation: true, **_ignored) end end - LoginAuthenticator = SASL::LoginAuthenticator + LoginAuthenticator = SASL::LoginAuthenticator # :nodoc: deprecate_constant :LoginAuthenticator end diff --git a/lib/net/imap/sasl/plain_authenticator.rb b/lib/net/imap/sasl/plain_authenticator.rb index d5ca089d..60c1db8c 100644 --- a/lib/net/imap/sasl/plain_authenticator.rb +++ b/lib/net/imap/sasl/plain_authenticator.rb @@ -118,7 +118,7 @@ def propset(name, value) end end - PlainAuthenticator = SASL::PlainAuthenticator + PlainAuthenticator = SASL::PlainAuthenticator # :nodoc: deprecate_constant :PlainAuthenticator end diff --git a/lib/net/imap/sasl/xoauth2_authenticator.rb b/lib/net/imap/sasl/xoauth2_authenticator.rb index 87cd9dee..1e55d8ae 100644 --- a/lib/net/imap/sasl/xoauth2_authenticator.rb +++ b/lib/net/imap/sasl/xoauth2_authenticator.rb @@ -105,7 +105,7 @@ def process(data) end end - XOauth2Authenticator = SASL::XOAuth2Authenticator + XOauth2Authenticator = SASL::XOAuth2Authenticator # :nodoc: deprecate_constant :XOauth2Authenticator end