Skip to content
This repository has been archived by the owner on Jul 3, 2024. It is now read-only.

Commit

Permalink
Stylefixes
Browse files Browse the repository at this point in the history
  • Loading branch information
mmoll committed Jun 28, 2019
1 parent 7600803 commit f0a9868
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 1 addition & 3 deletions app/controllers/foreman_xen/cache_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@ class CacheController < ::ApplicationController
def refresh
type = params[:type]

unless cache_attribute_whitelist.include?(type)
process_error(:error_msg => "Error refreshing cache. #{type} is not a white listed attribute")
end
process_error(:error_msg => "Error refreshing cache. #{type} is not a white listed attribute") unless cache_attribute_whitelist.include?(type)

unless @compute_resource.respond_to?("#{type}!")
process_error(:error_msg => "Error refreshing cache. Method '#{type}!' not found for compute resource" +
Expand Down
4 changes: 1 addition & 3 deletions test/test_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,4 @@
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }

# Load fixtures from the engine
if ActiveSupport::TestCase.method_defined?(:fixture_path=)
ActiveSupport::TestCase.fixture_path = File.expand_path('fixtures', __dir__)
end
ActiveSupport::TestCase.fixture_path = File.expand_path('fixtures', __dir__) if ActiveSupport::TestCase.method_defined?(:fixture_path=)

0 comments on commit f0a9868

Please sign in to comment.