Class: TentD::API::Apps::AuthorizeWriteOne
- Inherits:
-
Middleware
- Object
- Middleware
- TentD::API::Apps::AuthorizeWriteOne
- Defined in:
- lib/tentd/api/apps.rb
Instance Method Summary collapse
Methods inherited from Middleware
Methods included from TentD::API::Authorizable
#authorize_env!, #authorize_env?
Constructor Details
This class inherits a constructor from TentD::API::Middleware
Instance Method Details
#action(env) ⇒ Object
45 46 47 48 49 50 |
# File 'lib/tentd/api/apps.rb', line 45 def action(env) (env, :write_apps) unless env.params.app_id && env.current_auth && env.current_auth.kind_of?(Model::App) && env.current_auth.id == env.params.app_id env end |