Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
lslezak committed Feb 22, 2019
1 parent b789031 commit a206d26
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 16 deletions.
1 change: 1 addition & 0 deletions src/lib/registration/ssl_error_codes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ class SslErrorCodes
# @see https://www.openssl.org/docs/apps/verify.html
# @see https://github.com/openssl/openssl/blob/2c75f03b39de2fa7d006bc0f0d7c58235a54d9bb/include/openssl/x509_vfy.h#L99-L189
# @note the text messages need to be translated at runtime via _() call
# @note we do not translate every possible OpenSSL error message, just the most common ones
OPENSSL_ERROR_MESSAGES = {
# TRANSLATORS: SSL error message
EXPIRED => N_("Certificate has expired"),
Expand Down
16 changes: 0 additions & 16 deletions src/lib/registration/ui/import_certificate_dialog.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

require "registration/fingerprint"
require "registration/ssl_certificate_details"
require "registration/ssl_error_codes"

module Registration
module UI
Expand All @@ -16,21 +15,6 @@ class ImportCertificateDialog

attr_accessor :certificate

# error code => translatable error message
# @see https://www.openssl.org/docs/apps/verify.html
# @see https://github.com/openssl/openssl/blob/2c75f03b39de2fa7d006bc0f0d7c58235a54d9bb/include/openssl/x509_vfy.h#L99-L189
# @note the text messages need to be translated at runtime via _() call
OPENSSL_ERROR_MESSAGES = {
# SSL error message
SslErrorCodes::EXPIRED => N_("Certificate has expired"),
# SSL error message
SslErrorCodes::SELF_SIGNED_CERT => N_("Self signed certificate"),
# SSL error message
SslErrorCodes::SELF_SIGNED_CERT_IN_CHAIN => N_(
"Self signed certificate in certificate chain"
)
}.freeze

Yast.import "UI"
Yast.import "Label"

Expand Down

0 comments on commit a206d26

Please sign in to comment.