-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3267 from nebulab/kennyadsl/move-preferences-to-lib
Make preferences usage uniform across all Solidus gems
- Loading branch information
Showing
13 changed files
with
46 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,11 +2,4 @@ | |
|
||
require 'spree/core' | ||
|
||
require 'responders' | ||
|
||
module Spree | ||
module Api | ||
end | ||
end | ||
|
||
require 'spree/api/engine' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'spree/api_configuration' | ||
|
||
module Spree | ||
module Api | ||
Config = Spree::ApiConfiguration.new | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'rails/engine' | ||
require 'spree/api/config' | ||
|
||
module Spree | ||
module Api | ||
class Engine < Rails::Engine | ||
isolate_namespace Spree | ||
engine_name 'spree_api' | ||
|
||
initializer "spree.api.environment", before: :load_config_initializers do |_app| | ||
Spree::Api::Config = Spree::ApiConfiguration.new | ||
end | ||
# Leave initializer empty for backwards-compatability. Other apps | ||
# might still rely on this event. | ||
initializer "spree.api.environment", before: :load_config_initializers do; end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'responders' | ||
require 'spree/api/responders/rabl_template' | ||
|
||
module Spree | ||
|
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'spree/backend_configuration' | ||
|
||
module Spree | ||
module Backend | ||
Config = Spree::BackendConfiguration.new | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,15 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'spree/backend/config' | ||
|
||
module Spree | ||
module Backend | ||
class Engine < ::Rails::Engine | ||
config.middleware.use "Spree::Backend::Middleware::SeoAssist" | ||
|
||
initializer "spree.backend.environment", before: :load_config_initializers do |_app| | ||
Spree::Backend::Config = Spree::BackendConfiguration.new | ||
end | ||
# Leave initializer empty for backwards-compatability. Other apps | ||
# might still rely on this event. | ||
initializer "spree.backend.environment", before: :load_config_initializers do; end | ||
end | ||
end | ||
end |
4 changes: 3 additions & 1 deletion
4
...app/models/spree/backend_configuration.rb → backend/lib/spree/backend_configuration.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'spree/frontend_configuration' | ||
|
||
module Spree | ||
module Frontend | ||
Config = Spree::FrontendConfiguration.new | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,15 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'spree/frontend/config' | ||
|
||
module Spree | ||
module Frontend | ||
class Engine < ::Rails::Engine | ||
config.middleware.use "Spree::Frontend::Middleware::SeoAssist" | ||
|
||
initializer "spree.frontend.environment", before: :load_config_initializers do |_app| | ||
Spree::Frontend::Config = Spree::FrontendConfiguration.new | ||
end | ||
# Leave initializer empty for backwards-compatability. Other apps | ||
# might still rely on this event. | ||
initializer "spree.frontend.environment", before: :load_config_initializers do; end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters