Skip to content

Commit

Permalink
Fix bad example code in *public plugin documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyevans committed Jul 25, 2024
1 parent 0848bca commit 9891bdf
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions lib/roda/plugins/multi_public.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ module RodaPlugins
# font: 'assets/fonts',
# form: 'static/forms/pdfs'
#
# r.route do
# route do
# r.on "images" do
# r.multi_public(:img)
# end
Expand All @@ -43,7 +43,7 @@ module RodaPlugins
# 'fonts' => 'assets/fonts',
# 'forms' => 'static/forms/pdfs'
#
# r.route do
# route do
# r.on %w"images fonts forms" do |dir|
# r.multi_public(dir)
# end
Expand All @@ -58,7 +58,7 @@ module RodaPlugins
# 'fonts' => ['assets/fonts', {'Cache-Control'=>'max-age=31536000'}, 'font/ttf'],
# 'forms' => ['static/forms/pdfs', nil, 'application/pdf']
#
# r.route do
# route do
# r.on %w"images fonts forms" do |dir|
# r.multi_public(dir)
# end
Expand Down
2 changes: 1 addition & 1 deletion lib/roda/plugins/public.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ module RodaPlugins
# plugin :public, root: 'static'
#
# # Assuming public is the location of files
# r.route do
# route do
# # Make GET /images/foo.png look for public/images/foo.png
# r.public
#
Expand Down
2 changes: 1 addition & 1 deletion lib/roda/plugins/timestamp_public.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ module RodaPlugins
# plugin :public, root: 'static', prefix: 'public'
#
# # Assuming public is the location of files, and static is the path prefix
# r.route do
# route do
# # Make GET /static/1238099123/images/foo.png look for public/images/foo.png
# r.timestamp_public
#
Expand Down

0 comments on commit 9891bdf

Please sign in to comment.