File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
lib/ruby_lsp/ruby_lsp_rails/support Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -66,18 +66,22 @@ def generate_rails_document_urls(name)
66
66
private def build_search_index
67
67
return unless RAILTIES_VERSION
68
68
69
- $stderr. puts ( "Fetching Rails Documents... " )
69
+ $stderr. puts ( "Fetching search index for Rails documentation " )
70
70
71
71
response = Net ::HTTP . get_response ( URI ( "#{ RAILS_DOC_HOST } /v#{ RAILTIES_VERSION } /js/search_index.js" ) )
72
72
73
73
body = case response
74
74
when Net ::HTTPSuccess
75
+ $stderr. puts ( "Finished fetching search index for Rails documentation" )
75
76
response . body
76
77
when Net ::HTTPRedirection
77
78
# If the version's doc is not found, e.g. Rails main, it'll be redirected
78
79
# In this case, we just fetch the latest doc
79
80
response = Net ::HTTP . get_response ( URI ( "#{ RAILS_DOC_HOST } /js/search_index.js" ) )
80
- response . body if response . is_a? ( Net ::HTTPSuccess )
81
+ if response . is_a? ( Net ::HTTPSuccess )
82
+ $stderr. puts ( "Finished fetching search index for Rails documentation" )
83
+ response . body
84
+ end
81
85
else
82
86
$stderr. puts ( "Response failed: #{ response . inspect } " )
83
87
nil
You can’t perform that action at this time.
0 commit comments