Skip to content

Commit

Permalink
Minor tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
imobachgs committed Jul 26, 2016
1 parent e6926cb commit 0d248c0
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions src/lib/installation/clients/inst_update_installer.rb
Expand Up @@ -109,10 +109,10 @@ def self_update_enabled?
#
# @return [Array<URI>] self-update URLs
#
# @see #custom_self_update_url
# @see #default_self_update_url
# @see #custom_self_update_url
def self_update_urls
return @self_update_urls unless @self_update_urls.nil?
return @self_update_urls if @self_update_urls
@self_update_urls = Array(custom_self_update_url)
@self_update_urls = default_self_update_urls if @self_update_urls.empty?
log.info("self-update URLs are #{@self_update_urls}")
Expand All @@ -125,7 +125,7 @@ def self_update_urls
#
# @return [Array<URI>] self-update URLs
def default_self_update_urls
return @default_self_update_urls unless @default_self_update_urls.nil?
return @default_self_update_urls if @default_self_update_urls
@default_self_update_urls = self_update_url_from_connect
return @default_self_update_urls unless @default_self_update_urls.empty?
@default_self_update_urls = Array(self_update_url_from_control)
Expand All @@ -146,9 +146,10 @@ def custom_self_update_url
# Return the self-update URLs from SCC/SMT server
#
# Return an empty array if yast2-registration or SUSEConnect are not
# available (for instance in openSUSE). More than 1 URLs can be specified.
# available (for instance in openSUSE). More than 1 URLs can be found.
#
# As a side effect, it stores the URL of the registration server used.
# As a side effect, it stores the URL of the registration server used
# in the installation options.
#
# @return [Array<URI>] self-update URLs.
def self_update_url_from_connect
Expand All @@ -165,7 +166,7 @@ def self_update_url_from_connect
"for product '#{base_product}' are #{updates}")
updates.map { |u| URI(u.url) }
rescue SocketError => e
log.warn("Registration server could not be reached (URL: #{options.custom_url})")
log.warn("Registration server (URL #{options.custom_url}) could not be reached (#{e.message})")
if configure_network?(could_not_find_updates_msg)
retry
else
Expand Down Expand Up @@ -204,7 +205,7 @@ def registration_url
# :cancel if the dialog was dismissed.
def registration_service_from_user(services)
::Registration::UI::RegserviceSelectionDialog.run(
services: services,
services: services,
description: _("Select a detected registration server from the list\n" \
"to search for installer updates.")
)
Expand Down

0 comments on commit 0d248c0

Please sign in to comment.