lib/stasis/scope/controller.rb in stasis-0.1.7 vs lib/stasis/scope/controller.rb in stasis-0.1.8

- old
+ new

@@ -20,9 +20,12 @@ def _add(path) return unless File.file?(path) && File.basename(path) == 'controller.rb' # Temporarily set path variables. @_stasis.path = path + + # Change current working directory. + Dir.chdir(File.dirname(path)) # Evaluate `controller.rb`. instance_eval(File.read(path), path) # Unset temporary path variables. \ No newline at end of file