Permalink
Browse files

Adding an options attribute to ProjectModule

  • Loading branch information...
1 parent c079e1a commit 35844fc3aa3a64050c3eadddda6b4f54aee0aa3c Simon COURTOIS committed Apr 13, 2012
Showing with 5 additions and 5 deletions.
  1. +5 −5 padrino-admin/lib/padrino-admin/access_control.rb
@@ -145,20 +145,20 @@ def protect(path)
##
# Create a project module
#
- def project_module(name, path)
+ def project_module(name, path, options={})
allow(path)
- @project_modules << ProjectModule.new(name, path)
+ @project_modules << ProjectModule.new(name, path, options)
end
end # Authorization
##
# Project Module class
#
class ProjectModule
- attr_reader :name
+ attr_reader :name, :options
- def initialize(name, path) # @private
- @name, @path = name, path
+ def initialize(name, path, options={}) # @private
+ @name, @path, @options = name, path, options
end
##

0 comments on commit 35844fc

Please sign in to comment.