diff --git a/Gemfile.lock b/Gemfile.lock index bae2d9c8b..693ced03d 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -736,7 +736,7 @@ GEM simplecov_json_formatter (0.1.4) simpleidn (0.2.1) unf (~> 0.1.4) - sitemap_generator (6.1.2) + sitemap_generator (6.3.0) builder (~> 3.0) smart_properties (1.17.0) sorbet-runtime (0.5.11219) diff --git a/plugins/ShinySEO/app/models/shiny_seo/sitemap.rb b/plugins/ShinySEO/app/models/shiny_seo/sitemap.rb index b31de1ebe..186d55901 100644 --- a/plugins/ShinySEO/app/models/shiny_seo/sitemap.rb +++ b/plugins/ShinySEO/app/models/shiny_seo/sitemap.rb @@ -41,16 +41,13 @@ def items_for_sitemap def use_aws_sdk_adapter( s3_config ) require 'aws-sdk-s3' - SitemapGenerator::Sitemap.adapter = SitemapGenerator::AwsSdkAdapter.new( 's3_bucket', build( s3_config ) ) - end - - def build( s3_config ) - { + SitemapGenerator::Sitemap.adapter = SitemapGenerator::AwsSdkAdapter.new( + 's3_bucket', aws_secret_access_key: s3_config.secret_access_key, aws_access_key_id: s3_config.access_key_id, aws_region: s3_config.region, aws_endpoint: s3_config.base_url - } + ) end end end