Lockdown access to custom css and js files in repo
This commit is contained in:
@@ -144,6 +144,10 @@ module Precious
|
||||
end
|
||||
end
|
||||
|
||||
get %r{\/edit\/custom.(js|css)} do
|
||||
forbid
|
||||
end
|
||||
|
||||
get '/edit/*' do
|
||||
forbid unless @allow_editing
|
||||
wikip = wiki_page(params[:splat].first)
|
||||
@@ -212,6 +216,10 @@ module Precious
|
||||
end
|
||||
end
|
||||
|
||||
post %r{\/(deleteFile|rename|edit|revert)\/custom.(js|css)} do
|
||||
forbid
|
||||
end
|
||||
|
||||
post '/deleteFile/*' do
|
||||
forbid unless @allow_editing
|
||||
wiki = wiki_new
|
||||
|
||||
Reference in New Issue
Block a user