lib/socrates/core/dispatcher.rb in socrates-0.1.0 vs lib/socrates/core/dispatcher.rb in socrates-0.1.1
- old
+ new
@@ -9,10 +9,10 @@
module Core
class Dispatcher
def initialize(adapter:, state_factory:, storage: nil)
@adapter = adapter
@state_factory = state_factory
- @storage = storage || Storage::MemoryStorage.new
+ @storage = storage || Socrates::Config.storage || Storage::MemoryStorage.new
@logger = Socrates::Config.logger || Socrates::Logger.default
@error_message = Socrates::Config.error_message || DEFAULT_ERROR_MESSAGE
end