Permalink
Browse files

Fixed the loading order of an app's dependencies.

If we load apps first, libraries won't be there, hence throwing
exceptions at run time.
For example, this can be reproduced with any library that needs to be registered like ScssInitialiazer.
See #1448#issuecomment-26143346

Apps not being loaded at the last point makes things like libraries
  • Loading branch information...
dariocravero committed Oct 11, 2013
1 parent d64144f commit 64a99dba6b5f45d96e499c359af4320bf466b623
Showing with 1 addition and 1 deletion.
  1. +1 −1 padrino-core/lib/padrino-core/loader.rb
@@ -211,12 +211,12 @@ def load_paths_was
def dependency_paths_was
@_dependency_paths_was ||= [
- "#{root}/config/apps.rb",
"#{root}/config/database.rb",
"#{root}/lib/**/*.rb",
"#{root}/models/**/*.rb",
"#{root}/shared/lib/**/*.rb",
"#{root}/shared/models/**/*.rb",
+ "#{root}/config/apps.rb"
].freeze
end
end

0 comments on commit 64a99db

Please sign in to comment.