Module: Arturo
- Defined in:
- lib/arturo/feature.rb,
lib/arturo.rb,
lib/arturo/engine.rb,
lib/arturo/middleware.rb,
lib/arturo/feature_caching.rb,
lib/arturo/no_such_feature.rb,
lib/arturo/special_handling.rb,
lib/arturo/controller_filters.rb,
lib/arturo/feature_management.rb,
lib/arturo/feature_availability.rb,
lib/arturo/feature_params_support.rb,
app/helpers/arturo/features_helper.rb,
lib/generators/arturo/assets_generator.rb,
lib/generators/arturo/routes_generator.rb,
lib/generators/arturo/migration_generator.rb,
app/controllers/arturo/features_controller.rb,
lib/generators/arturo/initializer_generator.rb
Overview
TODO: this doesn’t do anything radically out of the ordinary.
Are there Rails 3 patterns/mixins/methods I can use
to clean it up a bit?
Defined Under Namespace
Modules: ControllerFilters, FeatureAvailability, FeatureCaching, FeatureManagement, FeatureParamsSupport, FeaturesHelper, SpecialHandling Classes: AssetsGenerator, Engine, Feature, FeaturesController, InitializerGenerator, Middleware, MigrationGenerator, NoSuchFeature, RoutesGenerator
Class Method Summary collapse
-
.feature_enabled_for?(feature_name, recipient) ⇒ true, false
Quick check for whether a feature is enabled for a recipient.
Class Method Details
.feature_enabled_for?(feature_name, recipient) ⇒ true, false
Quick check for whether a feature is enabled for a recipient.
14 15 16 17 |
# File 'lib/arturo.rb', line 14 def feature_enabled_for?(feature_name, recipient) f = self::Feature.to_feature(feature_name) f && f.enabled_for?(recipient) end |