Skip to content

Commit 4db89b5

Browse files
committed
chore: rubocop fmt
Signed-off-by: Mark Phelps <[email protected]>
1 parent 6ba777d commit 4db89b5

File tree

3 files changed

+14
-14
lines changed

3 files changed

+14
-14
lines changed

flipt-client-ruby/Gemfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: .
33
specs:
4-
flipt_client (0.17.0)
4+
flipt_client (1.0.0)
55

66
GEM
77
remote: https://rubygems.org/

flipt-client-ruby/lib/flipt_client/models.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ class TlsConfig
5656
# @param client_cert_data [String, nil] Raw client certificate content (PEM format)
5757
# @param client_key_data [String, nil] Raw client key content (PEM format)
5858
def initialize(ca_cert_file: nil, ca_cert_data: nil, insecure_skip_verify: nil,
59-
client_cert_file: nil, client_key_file: nil,
59+
client_cert_file: nil, client_key_file: nil,
6060
client_cert_data: nil, client_key_data: nil)
6161
@ca_cert_file = ca_cert_file
6262
@ca_cert_data = ca_cert_data
@@ -135,10 +135,10 @@ def validate_files!
135135

136136
def validate_file_exists(file_path, description)
137137
return if file_path.nil? || file_path.strip.empty?
138-
139-
unless File.exist?(file_path)
140-
raise ValidationError, "#{description} does not exist: #{file_path}"
141-
end
138+
139+
return if File.exist?(file_path)
140+
141+
raise ValidationError, "#{description} does not exist: #{file_path}"
142142
end
143143
end
144144

flipt-client-ruby/spec/client_spec.rb

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,21 +6,21 @@
66
before(:all) do
77
url = ENV.fetch('FLIPT_URL', 'http://localhost:8080')
88
auth_token = ENV.fetch('FLIPT_AUTH_TOKEN', 'secret')
9-
9+
1010
# Configure TLS if HTTPS URL is provided
1111
tls_config = nil
1212
if url.start_with?('https://')
1313
ca_cert_path = ENV['FLIPT_CA_CERT_PATH']
14-
if ca_cert_path && !ca_cert_path.empty?
15-
tls_config = Flipt::TlsConfig.with_ca_cert_file(ca_cert_path)
16-
else
17-
# Fallback to insecure for local testing
18-
tls_config = Flipt::TlsConfig.insecure
19-
end
14+
tls_config = if ca_cert_path && !ca_cert_path.empty?
15+
Flipt::TlsConfig.with_ca_cert_file(ca_cert_path)
16+
else
17+
# Fallback to insecure for local testing
18+
Flipt::TlsConfig.insecure
19+
end
2020
end
2121

2222
@client = Flipt::Client.new(
23-
url: url,
23+
url: url,
2424
authentication: Flipt::ClientTokenAuthentication.new(auth_token),
2525
tls_config: tls_config
2626
)

0 commit comments

Comments
 (0)