Created
April 27, 2020 15:45
-
-
Save electron0zero/16b34e6fd5058042edb6a0520905c77d to your computer and use it in GitHub Desktop.
Getting things from flipper with Active Recrod backend
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# flipper with ActiveRecord backend, taken from | |
# https://github.com/jnunemaker/flipper/blob/master/examples/active_record/internals.rb | |
# get all features | |
ap Flipper::Adapters::ActiveRecord::Feature.all | |
# get all actors which have a feature enabled | |
feature_name = "scope_by_tag_group.pg_lookup" | |
ap Flipper::Adapters::ActiveRecord::Gate.where(feature_key: feature_name) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment