All Versions
Latest Version
Avg Release Cycle
271 days
Latest Release
542 days ago

Changelog History
Page 1

  • v2.1.1 Changes

    August 13, 2021

    ๐Ÿš€ Friday 13th-release!

    ๐Ÿ›  Careful! The bugfix below (#626) could break existing code. If you rely on the return value for authorize and namespaced policies you might need to do some ๐Ÿ”„ changes.

    ๐Ÿ›  Fixed

    • .authorize and #authorize return the instance, even for namespaced policies (#626)

    ๐Ÿ”„ Changed

    • Generate application scope with protected attr_readers. (#616)

    โœ‚ Removed

    • โฌ‡๏ธ Dropped support for Ruby end-of-life versions: 2.1 and 2.2. (#604)
    • โฌ‡๏ธ Dropped support for Ruby end-of-life versions: 2.3 (#633)
    • โฌ‡๏ธ Dropped support for Ruby end-of-life versions: 2.4, 2.5 and JRuby 9.1 (#676)
    • โฌ‡๏ธ Dropped support for RSpec 2 (#615)
  • v2.1.0 Changes

    August 14, 2019

    ๐Ÿ›  Fixed

    • Avoid name clashes with the Error class. (#590)

    ๐Ÿ”„ Changed

    • 0๏ธโƒฃ Return a safer default NotAuthorizedError message. (#583)
  • v2.0.1 Changes

    January 18, 2019

    ๐Ÿ’ฅ Breaking changes


    Other changes

    • Improve exception handling for #policy_scope and #policy_scope!. (#550)
    • โž• Add :policy metadata to RSpec template. (#566)
  • v2.0.0 Changes

    July 21, 2018

    No changes since beta1

  • v2.0.0.beta1 Changes

    July 04, 2018

    ๐Ÿ’ฅ Breaking changes

    • Only pass last element of "namespace array" to policy and scope. (#529)
    • Raise InvalidConstructorError if a policy or policy scope with an invalid constructor is called. (#462)
    • Return passed object from #authorize method to make chaining possible. (#385)

    Other changes

    • โž• Add policy_class option to authorize to be able to override the policy. (#441)
    • Add policy_scope_class option to authorize to be able to override the policy scope. (#441)
    • ๐Ÿ›  Fix param_key issue when passed an array. (#529)
    • ๐Ÿ‘ Allow specification of a NilClassPolicy. (#525)
    • ๐Ÿ‘‰ Make sure policy_class override is called when passed an array. (#475)

    • ๐Ÿ‘‰ Use action_name instead of params[:action]. (#419)

    • Add pundit_params_for method to make it easy to customize params fetching. (#502)

  • v1.1.0 Changes

    January 14, 2016
    • Can retrieve policies via an array of symbols/objects.
    • โž• Add autodetection of param key to permitted_attributes helper.
    • Hide some methods which should not be actions.
    • Permitted attributes should be expanded.
    • Generator uses RSpec.describe according to modern best practices.
  • v1.0.1 Changes

    May 27, 2015
    • ๐Ÿ›  Fixed a regression where NotAuthorizedError could not be ininitialized with a string.
    • ๐Ÿ‘‰ Use camelize instead of classify for symbol policies to prevent weird pluralizations.
  • v1.0.0 Changes

    April 19, 2015
    • Caches policy scopes and policies.
    • ๐Ÿšš Explicitly setting the policy for the controller via controller.policy = foo has been removed. Instead use controller.policies[record] = foo.
    • ๐Ÿšš Explicitly setting the policy scope for the controller via controller.policy_policy = foo has been removed. Instead use controller.policy_scopes[scope] = foo.
    • โž• Add permitted_attributes helper to fetch attributes from policy.
    • Add pundit_policy_authorized? and pundit_policy_scoped? methods.
    • ๐Ÿ›  Instance variables are prefixed to avoid collisions.
    • โž• Add Pundit.authorize method.
    • Add skip_authorization and skip_policy_scope helpers.
    • ๐Ÿ‘ Better errors when checking multiple permissions in RSpec tests.
    • ๐Ÿ‘ Better errors in case nil is passed to policy or policy_scope.
    • ๐Ÿ–จ Use inspect when printing object for better errors.
    • โฌ‡๏ธ Dropped official support for Ruby 1.9.3
  • v0.3.0 Changes

    August 22, 2014
    • 0๏ธโƒฃ Extend the default ApplicationPolicy with an ApplicationPolicy::Scope (#120)
    • ๐Ÿ›  Fix RSpec 3 deprecation warnings for built-in matchers (#162)
    • โœ… Generate blank policy spec/test files for Rspec/MiniTest/Test::Unit in Rails (#138)
  • v0.2.3 Changes

    April 06, 2014
    • Customizable error messages: #query, #record and #policy methods on Pundit::NotAuthorizedError (#114)
    • Raise a different Pundit::AuthorizationNotPerformedError when authorize call is expected in controller action but missing (#109)
    • โšก๏ธ Update Rspec matchers for Rspec 3 (#124)