Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: dszczyt/cancan
base: 1.6.6
...
head fork: bryanrite/cancan
compare: master
Commits on Oct 04, 2011
@ryanb ryanb quick fix to get nested resources working again - closes #482 67a3038
@ryanb ryanb releasing 1.6.7 with nested resource fix 9eebeb2
Commits on Oct 15, 2011
@soopa soopa fix uninitialized constant warning in CanCan::Rule#model_adapter 80ceaf8
Commits on Oct 31, 2011
@rogercampos rogercampos Adding Ability#merge 7797b37
Commits on Nov 03, 2011
@nertzy nertzy Use latest with_model gem
Now with_model clears the association class cache
between specs, which fixes a test pollution
problem.
9831294
Commits on Nov 09, 2011
@moffff moffff Fixed problem with 'with_model' gem in DataMapper tests and Mongoid t…
…ests.
f18f53c
Commits on Dec 25, 2011
@manuelmeurer manuelmeurer Fixed typo e65f9bd
Commits on Jan 05, 2012
@icrowley icrowley Fixed bug with params for actions that build new instances with names…
…paced models
baadcb9
Commits on Feb 02, 2012
@mauriciozaffari mauriciozaffari Pass forward :if and :unless options to the before filter. i.e:
    load_and_authorize_resource :if => condition == true
83e2dce
Commits on Feb 15, 2012
@plentz plentz adding travis-ci badge 37a42e3
Commits on Feb 29, 2012
@flop flop Don't remove key-value from the subject hash we might want to use it …
…again.
ba01349
Commits on Mar 22, 2012
Dmitriy Vorotilin Just add singleton to description of authorize_resource f166b59
Commits on Apr 03, 2012
@spatil spatil checked for ActionContoller::Base instead of just ActionContoller 51702e0
Commits on Apr 17, 2012
@ryanb ryanb adding project status message to readme aed37cd
Commits on Apr 23, 2012
@Aryk Aryk Add check for Enumerable as condition value 65bbf0e
Commits on May 10, 2012
@ryanb ryanb Merge pull request #607 from Mixbook/master
Added support for value to be Enumerable
6e8bc85
@ryanb ryanb Merge pull request #587 from route/patch-1
Just add singleton to description of authorize_resource
78e1a17
@ryanb ryanb Merge pull request #559 from plentz/patch-1
Adding travis-ci badge
d117624
@ryanb ryanb Merge pull request #564 from flop/master
False positives on multiple nested abilities definitions
b73bd06
@ryanb ryanb Merge pull request #556 from mauriciozaffari/master
Pass forward :if and :unless options to the before filter.
70515de
@ryanb ryanb Merge pull request #505 from nertzy/update_with_model
Use latest with_model gem
c1f7181
@ryanb ryanb Merge pull request #541 from icrowley/master
Fixed bug with params for actions that build new instances with namespaced models
a8a85f1
@ryanb ryanb adding a .rbenv-version file 10cbfbb
@NickClark NickClark Clarify readme for rails 2.3 users 0bbe2e1
Commits on May 11, 2012
@Gimi Gimi Merge pull request #616 from NickClark/rails_2_3_readme_clarification
Clarify readme for rails 2.3 users
8e46cca
@Gimi Gimi Merge pull request #535 from manuelmeurer/patch-2
Fixed a small typo
14e1f5c
@ryanb ryanb Merge pull request #492 from soopa/master
Fix "uninitialized constant CanCan::Rule::ModelAdapters"
7f4f469
@ryanb ryanb Merge pull request #509 from moffff/master
Fix 'spec/spec_helper.rb:20: uninitialized constant WithModel (NameError)'
1cdd7b3
Commits on May 14, 2012
@cgunther cgunther port fix for namespaced params from 2.0 back to 1.6 b347c7b
@ryanb ryanb Merge pull request #619 from derekprior/namespace-fix
Updated: port fix for namespaced params from 2.0 back to 1.6
0c21831
Commits on May 26, 2012
@andhapp andhapp Fix to handle MetaWhere and non-MetaWhere conditions correctly. c27ead5
Commits on May 28, 2012
@ryanb ryanb Merge pull request #625 from rogercampos/merging
Adding Ability#merge
b3f9ffe
Commits on May 29, 2012
@ryanb ryanb Merge pull request #632 from andhapp/fix-issue-327
Fix to handle MetaWhere and non-MetaWhere conditions correctly.
80a8c39
Commits on Jun 10, 2012
@andhapp andhapp Fix for issue-644 to allow users to specify a mix of can and cannot r…
…ules with mongo.
da663aa
Commits on Jun 11, 2012
@ryanb ryanb Merge pull request #645 from andhapp/issue-644
Allow users to specify a mix of can and cannot rule for mongoid
7bf683d
Commits on Jun 18, 2012
@marksim marksim Fixes Nested Resource Loading d5baed6
@mccraigmccraig mccraigmccraig initialise attributes after a resource is created by an InheritedReso…
…urces controller
c2c0b86
@mikepack mikepack Add specs for resource attributes.
Remove inconsistent line breaks.
b965f5b
@mikepack mikepack Refactor out attribute assignment 88aba46
@andhapp andhapp Fix pull request 640. For some reason github didn't allow a clean mer…
…ge althought there weren't any conflicts. Fix it so that it's easier to just merge via the UI.
a1254ca
Commits on Jun 19, 2012
@DavidMikeSimon DavidMikeSimon Fix for issue 560 where joins could be thrown away by ActiveRecordAda…
…pter::merge_joins
cfc355c
@ryanb ryanb Merge pull request #618 from spatil/master
Check for defined ActionController::Base instead ActionController
33e33c5
@ryanb ryanb Merge pull request #650 from andhapp/fix-pull-request-486
Fixes Nested Resource Loading
aff8ca6
@ryanb ryanb Merge pull request #653 from andhapp/fix-pull-request-640
Init attributes in InheritedResources controller w/ specs
2b89dbb
@ryanb ryanb load ostruct for OpenStruct used in spec 9448041
@ryanb ryanb clearing leftover whitespace 112a995
@ryanb ryanb removing project status section from readme since contributors are no…
…w kind enough to keep tabs on the issue tracker
a020016
@ryanb ryanb updating changelog 6d7bce7
@ryanb ryanb preparing for 1.6.8 5f1be25
@DavidMikeSimon DavidMikeSimon Spec to test against nested joins being thrown away ala issue 560 b162871
Commits on Jun 23, 2012
@fl00r fl00r Fixing Segmentation fault on aliasing 925274d
Commits on Jun 25, 2012
@ryanb ryanb releasing 1.6.8 1e89b31
Commits on Jun 29, 2012
@andhapp andhapp Add code for fixing issue #664 (regression in 1.6.8). 60bc9e9
Commits on Jul 02, 2012
@xinuc xinuc porting #668 to 1.6.x ce7d3fe
@brynary brynary Add Code Climate badge 8b993ee
@ryanb ryanb Merge pull request #655 from DavidMikeSimon/master
Fix for issue #560
d20d90d
@ryanb ryanb Merge pull request #660 from fl00r/master
Segmentation fault on aliasing
cad4db2
@ryanb ryanb Merge pull request #670 from andhapp/fix-issue-664
Namespaced Controllers not building new resource from params(regression 1.6.8)
2db73e6
Commits on Jul 03, 2012
@ryanb ryanb Merge pull request #676 from brynary/master
Add Code Climate badge
b4285ae
Commits on Jul 30, 2012
@albertobajo albertobajo Fixed load_resource "find_by" in mongoid resources
Latest versions of Mongoid supports "find_by" query, but syntax
is slightly different than Active Record.
4a5700c
Commits on Aug 01, 2012
@calebthompson calebthompson Refold generated Ability comments at 80 characters
A lot of people still fold their code at 80 characters, so it is
nice to have generated code consider this.
857dd07
Commits on Oct 13, 2012
@nashby nashby show build status fro master branch 9a84277
@nashby nashby add contributing guide
[ci skip]
d4be93b
Commits on Oct 15, 2012
@nashby nashby Merge pull request #708 from calebthompson/patch-1
Refold generated Ability comments at 80 characters
3b50fed
Commits on Oct 24, 2012
@jonsgreen jonsgreen Issue #687: cancan inserting "AND (NULL)" at the end of sql
Ensure that empty conditions does not trigger unmergeable conditions
f5b3fcd
Commits on Oct 25, 2012
@ryanb ryanb Merge pull request #765 from jonsgreen/issue/cancan_inserting_and_nul…
…l_687

Issue #687: cancan inserting "AND (NULL)" at the end of sql
4dcd544
Commits on Dec 12, 2012
@ryanb ryanb add gem version badge (thanks Gemfury) 3f4ee12
Commits on Jan 03, 2013
@steerio steerio Working around CVE-2012-5664 d5123e0
@steerio steerio Creating a Project here is unnecessary d3a8929
Commits on Jan 20, 2013
@yuszuv yuszuv added support for nested join conditions e3ba668
Commits on Feb 04, 2013
@ryanb ryanb releasing 1.6.9 38d4654
Commits on Feb 20, 2013
Ben Moss Add docs for id_param option of load_resource
Added in ryanb#425 but lacked documentation
9f7f520
Commits on Feb 22, 2013
@ryanb ryanb Merge pull request #800 from wopata/master
Working around a SQL Injection Vulnerability in Ruby on Rails (CVE-2012-5664)
1cb33bd
@ryanb ryanb Merge pull request #806 from yuszuv/support_for_nested_joins
added support for nested join conditions
cbd352c
@ryanb ryanb Merge pull request #705 from albertobajo/mongoid_find_by
Fixed load_resource "find_by" in mongoid resources
ba82241
@nashby nashby Merge pull request #728 from zephyr-dev/patch-1
Add docs for id_param option of load_resource
ff2b632
Commits on Feb 28, 2013
@vfrride vfrride updates src url to use https
helps prevent man in the middle attacks
7b6965a
Commits on Mar 20, 2013
Nícolas Iensen Update README.rdoc 0b15de7
Commits on Apr 05, 2013
@twe4ked twe4ked Fix whitespace in generated ability.rb f38d3e2
Commits on May 03, 2013
@ryanb ryanb Merge pull request #675 from bukalapak/master
porting #668 to master branch
60cf6a6
Commits on May 07, 2013
@ryanb ryanb fix matches_conditons_hash for string values on 1.8 ea2b07f
@ryanb ryanb releasing 1.6.10 f2f40c7
Commits on Jul 13, 2013
@inossidabile inossidabile Comment typo fixed 1f3ca49
@jeremyf jeremyf Merge pull request #898 from inossidabile/typo-fix
Comment typo fixed
440bd88
Commits on Jul 20, 2013
@kimberninger kimberninger Fixed a typo in README.rdoc c1979e8
Commits on Aug 26, 2013
@benmoss benmoss Fix docs typo 750e377
Commits on Sep 06, 2013
@nashby nashby Merge pull request #903 from kimberninger/patch-1
Fixed a typo in README.rdoc [ci skip]
acf12c3
@nashby nashby Merge pull request #926 from benmoss/patch-1
Fix docs typo [ci skip]
2d50734
@nashby nashby Merge pull request #828 from vfrride/patch-1
updates src url to use https
d7bd6b1
@nashby nashby Merge pull request #841 from nicolasiensen/patch-1
Change Code Climate badge
f6c1052
@nashby nashby Merge pull request #848 from twe4ked/fix-generated-file-whitespace
Fix whitespace in generated ability.rb
4560928
Commits on Jan 27, 2014
@ricec ricec Fixes nested ability conditions in issue #859 2ea73a9
@knoopx knoopx FIX: Variable collision prevents defining permissions with multiple n…
…ested conditions
e87464b
@inkstak inkstak Use scoped to avoid sql query execution c8aec29
@inkstak inkstak Avoid deprecation warning with AR 4 5155f63
@inkstak inkstak Update to pass specs 375c012
@rahul-tapali rahul-tapali Changing [].flatten to array wrapper method a1ba470
@matt-glover matt-glover Do not execute the scope condition on class permission checks.
@conditions.empty? calls ActiveRecord::Relation#empty? when a scoped condition is provided. ActiveRecord::Relation#empty? will query the database while CanCan only needs to check if conditions are set on the rule.
d3e4fd7
@francocatena francocatena id_param now returns nil when the param is nil ba5294d
@francocatena francocatena treat ActiveRecord::Relation as Array 44c2ca7
@francocatena francocatena Fix typo d5a0732
@bryanrite bryanrite Remove .rvmrc, use .ruby-version, and move to 1.9.3 bd755e2
Jonas Nicklas and Nicklas Ramhöj Allow multiple abilities with associations
There are two issues with the current way cancan handles associations:

1) Records are returned multiple times in some circumstances
2) Several defined abilities prevent some records to show up under certain circumstances

This commit includes tests for both cases. It fixes both problems by changing `joins` to `includes` for the AR adapters. This could have performance implications, since `includes` will also select all columns in the associated records. We tried various ways of achieving the same thing using Arel directly, but were unable to make this work due to lack of support for outer joins in Rails 3.1.

This closes issues #724, #566 and #613
8976293
@ogerman ogerman removed rr, bump rspec version to 2.14, expect syntax, ruby 1.9.3/2.0…
….0 compatible
cd04d23
@ogerman ogerman ruby 1.8 style hash syntax a30dfb2
@ogerman ogerman use expect syntax for Mongoid and DataMappper specs be24a2c
@ryanb ryanb removed should spec wording, same as on the 2nd branch b5bfda6
Eric Chapweske Reduce object allocations 04acbdc
@bryanrite bryanrite Fixes to specs for spec update. 3c97fb3
Commits on Jan 28, 2014
@bryanrite bryanrite Support for strong_parameters 23b2ed6
@bryanrite bryanrite Merge pull request #1 from bryanrite/yet_another_strong_params_support
Support for strong_parameters
535e5db
@bryanrite bryanrite Run against modern rubies. d76b2b0
@bryanrite bryanrite Add back in 1.8.7 support. 8e70203
Commits on Jan 29, 2014
@bryanrite bryanrite add jruby and rubinus to travis 014f513