Skip to content

Commit

Permalink
Run bundle add solidus_admin only when missing
Browse files Browse the repository at this point in the history
This avoids errors when running the installer on apps that already
include that gem, for example when creating the sandbox.
  • Loading branch information
spaghetticode committed Jan 24, 2024
1 parent b4f14e8 commit 17647e5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion core/lib/generators/solidus/install/install_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,9 @@ def install_solidus_admin
return unless options[:admin_preview]

say_status :installing, "SolidusAdmin", :blue
bundle_command 'add solidus_admin -v ">= 0.2"'
unless File.read(app_path.join('Gemfile')).include?('solidus_admin')
bundle_command 'add solidus_admin -v ">= 0.2"'
end
generate 'solidus_admin:install'
end

Expand Down

0 comments on commit 17647e5

Please sign in to comment.