Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Rename class and add fixme

  • Loading branch information...
commit 578770b043fdd37ad02ff07499ff112c4f7ea4b5 1 parent 5cf55d0
@paulcbetts authored
Showing with 5 additions and 6 deletions.
  1. +5 −6 lib/controllers.rb
View
11 lib/controllers.rb
@@ -42,9 +42,10 @@
Ramaze::Global.public_root = File.join AppConfig::RootDir, 'public'
-### Helper Mixins
+### Helper Classes
-module StaticFileMixin
+# FIXME: This creates a broken mapping to /static_file
+class StaticFileControllerBase < Ramaze::Controller
def index(*paths)
do_send_file File.join(paths)
end
@@ -124,8 +125,7 @@ def url_base
end
end
-class FilesController < Ramaze::Controller
- include StaticFileMixin
+class FilesController < StaticFileControllerBase
map '/files'
protected
@@ -134,8 +134,7 @@ def get_file_path
end
end
-class PreviewController < Ramaze::Controller
- include StaticFileMixin
+class PreviewController < StaticFileControllerBase
map '/preview'
protected
Please sign in to comment.
Something went wrong with that request. Please try again.